class_docstr: IODescriptor describes the input/output data format of an InferenceAPI defined
  in a :code:`bentoml.Service`. This is an abstract base class for extending new HTTP
  endpoint IO descriptor types in BentoServer.
docstr: Creates a new instance of the IO Descriptor from given sample.
  
  Args:
      sample: The sample to create the instance from.
      **kwargs: Additional keyword arguments to pass to the constructor.
  
  Returns:
      An instance of the IODescriptor.
docstr_tok: ["Creates","a","new","instance","of","the","IO","Descriptor","from","given","sample",".","Args",":","sample",":","The","sample","to","create","the","instance","from",".","*","*","kwargs",":","Additional","keyword","arguments","to","pass","to","the","constructor",".","Returns",":","An","instance","of","the","IODescriptor","."]
code: def _from_sample(self, sample: t.Any) -> IOType:
      """
      Creates a new instance of the IO Descriptor from given sample.
  
      Args:
          sample: The sample to create the instance from.
          **kwargs: Additional keyword arguments to pass to the constructor.
  
      Returns:
          An instance of the IODescriptor.
      """
      raise NotImplementedError
  
imports: from __future__ import annotations
  import typing
  from abc import ABC
  from abc import abstractmethod
  from functools import update_wrapper
  from ...exceptions import InvalidArgument
label_desc: Use image node_id 5 for calling the IODescriptor obj's underlying member method code with example usage: obj._from_sample(sample) without return types