{"record":{"id":"7415d6895fc5b95e","repo":"tensorflow/models","slug":"unknown-input-file-type-r","errorCode":null,"errorMessage":"Unknown input file type {!r}","messagePattern":"Unknown input file type (.+?)","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/vision/tasks/video_classification.py","lineNumber":111,"sourceCode":"      ckpt = tf.train.Checkpoint(model=model)\n      status = ckpt.read(ckpt_dir_or_file)\n      status.expect_partial().assert_existing_objects_matched()\n    elif self.task_config.init_checkpoint_modules == 'backbone':\n      ckpt = tf.train.Checkpoint(backbone=model.backbone)\n      status = ckpt.read(ckpt_dir_or_file)\n      status.expect_partial().assert_existing_objects_matched()\n    else:\n      raise ValueError(\n          \"Only 'all' or 'backbone' can be used to initialize the model.\")\n\n    logging.info('Finished loading pretrained checkpoint from %s',\n                 ckpt_dir_or_file)\n\n  def _get_dataset_fn(self, params):\n    if params.file_type == 'tfrecord':\n      return tf.data.TFRecordDataset\n    else:\n      raise ValueError('Unknown input file type {!r}'.format(params.file_type))\n\n  def _get_decoder_fn(self, params):\n    if params.tfds_name:\n      decoder = video_input.VideoTfdsDecoder(\n          image_key=params.image_field_key, label_key=params.label_field_key)\n    else:\n      decoder = video_input.Decoder(\n          image_key=params.image_field_key, label_key=params.label_field_key)\n    if self.task_config.train_data.output_audio:\n      assert self.task_config.train_data.audio_feature, 'audio feature is empty'\n      decoder.add_feature(self.task_config.train_data.audio_feature,\n                          tf.io.VarLenFeature(dtype=tf.float32))\n    return decoder.decode\n\n  def build_inputs(self,\n                   params: exp_cfg.DataConfig,\n                   input_context: Optional[tf.distribute.InputContext] = None):\n    \"\"\"Builds classification input.\"\"\"","sourceCodeStart":93,"sourceCodeEnd":129,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/vision/tasks/video_classification.py#L93-L129","documentation":"Error \"Unknown input file type {!r}\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/vision/tasks/video_classification.py:111 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use a supported input file type such as 'tfrecord' or 'video' for the video classification input.","Check the input file type extension/config for typos."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e006f5f0d534913e49c1f1dae87364039fa607e2","analyzedAt":"2026-08-24T14:09:15.576Z","schemaVersion":2},"datasetVersion":"2026-08-24T17:17:21.512Z"}