{"record":{"id":"dd61a9d60ff451bb","repo":"tensorflow/models","slug":"video-classification-do-not-support-image-bytes-in","errorCode":null,"errorMessage":"Video classification do not support image bytes input.","messagePattern":"Video classification do not support image bytes input\\.","errorType":"exception","errorClass":"NotImplementedError","httpStatus":null,"severity":"error","filePath":"official/vision/serving/video_classification.py","lineNumber":112,"sourceCode":"            fn_output_signature={\n                video_input.IMAGE_KEY: tf.string,\n            })\n        return self.serve(inputs[video_input.IMAGE_KEY], tf.zeros([1, 1]))\n\n  @tf.function\n  def inference_from_image_tensors(\n      self, input_frames: tf.Tensor) -> Mapping[str, tf.Tensor]:\n    return self.serve(input_frames, tf.zeros([1, 1]))\n\n  @tf.function\n  def inference_from_image_audio_tensors(\n      self, input_frames: tf.Tensor,\n      input_audio: tf.Tensor) -> Mapping[str, tf.Tensor]:\n    return self.serve(input_frames, input_audio)\n\n  @tf.function\n  def inference_from_image_bytes(self, inputs: tf.Tensor):\n    raise NotImplementedError(\n        'Video classification do not support image bytes input.')\n\n  def serve(self, input_frames: tf.Tensor, input_audio: tf.Tensor):\n    \"\"\"Cast image to float and run inference.\n\n    Args:\n      input_frames: uint8 Tensor of shape [batch_size, None, None, 3]\n      input_audio: float32\n\n    Returns:\n      Tensor holding classification output logits.\n    \"\"\"\n    with tf.device('cpu:0'):\n      inputs = tf.map_fn(\n          self._preprocess_image, (input_frames),\n          fn_output_signature={\n              'image': tf.float32,\n          })","sourceCodeStart":94,"sourceCodeEnd":130,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/vision/serving/video_classification.py#L94-L130","documentation":"Error \"Video classification do not support image bytes input.\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/vision/serving/video_classification.py:112 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use input_type 'image_tensor' (decoded frames) for video classification serving.","Decode video/image bytes to tensors on the client side before sending."],"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"}