class_docstr: Lightweight predictor for local deployment in IN_PROCESS and LOCAL_CONTAINER modes
class_docstr_tok: ["Lightweight","predictor","for","local","deployment","in","IN_PROCESS","and","LOCAL_CONTAINER","modes"]
code: def __init__(
      self,
      mode_obj: Type[LocalContainerMode],
      serializer=IdentitySerializer(),
      deserializer=BytesDeserializer(),
  ):
      self._mode_obj = mode_obj
      self.serializer = serializer
      self.deserializer = deserializer
  
imports: from __future__ import absolute_import
  import io
  from typing import Type
  from sagemaker import Session
  from sagemaker.serve.mode.local_container_mode import LocalContainerMode
  from sagemaker.serve.builder.schema_builder import SchemaBuilder
  from sagemaker.serializers import IdentitySerializer, JSONSerializer
  from sagemaker.deserializers import BytesDeserializer, JSONDeserializer
  from sagemaker.base_predictor import PredictorBase, Predictor
  from sagemaker.serve.utils.types import ModelServer
  from sagemaker.serve.model_server.triton.triton_builder import TritonSerializer
label_desc: Use image node_id 1 to create a new TorchServeLocalPredictor object from inherited base classes: PredictorBase with example: obj = TorchServeLocalPredictor(mode_obj, serializer, deserializer)