docstr: Creates or updates the prediction task schema.
  
  Args:
      schema:
          The prediction task schema.
      prediction_version_id:
          A numerical ID (e.g., timestamp) to distinguish different predictions of different model versions.
          Use the same ID if you don't require versioning or if you wish to overwrite the previous schema.
  
  Example:
    >>> import time
    >>> from lightly.api import ApiWorkflowClient
    >>> from lightly.openapi_generated.swagger_client.models import (
    >>>     PredictionTaskSchema,
    >>>     TaskType,
    >>>     PredictionTaskSchemaCategory,
    >>> )
    >>>
    >>> client = ApiWorkflowClient(
    >>>     token="MY_LIGHTLY_TOKEN", dataset_id="MY_DATASET_ID"
    >>> )
    >>>
    >>> schema = PredictionTaskSchema(
    >>>     name="my-object-detection",
    >>>     type=TaskType.OBJECT_DETECTION,
    >>>     categories=[
    >>>         PredictionTaskSchemaCategory(id=0, name="dog"),
    >>>         PredictionTaskSchemaCategory(id=1, name="cat"),
    >>>     ],
    >>> )
    >>> client.create_or_update_prediction_task_schema(schema=schema)
  
  :meta private:  # Skip docstring generation
docstr_tok: ["Creates","or","updates","the","prediction","task","schema",".","Args",":","schema",":","The","prediction","task","schema",".","prediction_version_id",":","A","numerical","ID","(","e.g.",",","timestamp",")","to","distinguish","different","predictions","of","different","model","versions",".","Use","the","same","ID","if","you","do","n't","require","versioning","or","if","you","wish","to","overwrite","the","previous","schema",".","Example",":",">",">",">","import","time",">",">",">","from","lightly.api","import","ApiWorkflowClient",">",">",">","from","lightly.openapi_generated.swagger_client.models","import","(",">",">",">","PredictionTaskSchema",",",">",">",">","TaskType",",",">",">",">","PredictionTaskSchemaCategory",",",">",">",">",")",">",">",">",">",">",">","client","=","ApiWorkflowClient","(",">",">",">","token=","''","MY_LIGHTLY_TOKEN","''",",","dataset_id=","''","MY_DATASET_ID","''",">",">",">",")",">",">",">",">",">",">","schema","=","PredictionTaskSchema","(",">",">",">","name=","''","my-object-detection","''",",",">",">",">","type=TaskType.OBJECT_DETECTION",",",">",">",">","categories=","[",">",">",">","PredictionTaskSchemaCategory","(","id=0",",","name=","''","dog","''",")",",",">",">",">","PredictionTaskSchemaCategory","(","id=1",",","name=","''","cat","''",")",",",">",">",">","]",",",">",">",">",")",">",">",">","client.create_or_update_prediction_task_schema","(","schema=schema",")",":","meta","private",":","#","Skip","docstring","generation"]
code: def create_or_update_prediction_task_schema(
      self,
      schema: PredictionTaskSchema,
      prediction_version_id: int = -1,
  ) -> None:
      """Creates or updates the prediction task schema.
  
      Args:
          schema:
              The prediction task schema.
          prediction_version_id:
              A numerical ID (e.g., timestamp) to distinguish different predictions of different model versions.
              Use the same ID if you don't require versioning or if you wish to overwrite the previous schema.
  
      Example:
        >>> import time
        >>> from lightly.api import ApiWorkflowClient
        >>> from lightly.openapi_generated.swagger_client.models import (
        >>>     PredictionTaskSchema,
        >>>     TaskType,
        >>>     PredictionTaskSchemaCategory,
        >>> )
        >>>
        >>> client = ApiWorkflowClient(
        >>>     token="MY_LIGHTLY_TOKEN", dataset_id="MY_DATASET_ID"
        >>> )
        >>>
        >>> schema = PredictionTaskSchema(
        >>>     name="my-object-detection",
        >>>     type=TaskType.OBJECT_DETECTION,
        >>>     categories=[
        >>>         PredictionTaskSchemaCategory(id=0, name="dog"),
        >>>         PredictionTaskSchemaCategory(id=1, name="cat"),
        >>>     ],
        >>> )
        >>> client.create_or_update_prediction_task_schema(schema=schema)
  
      :meta private:  # Skip docstring generation
      """
      self._predictions_api.create_or_update_prediction_task_schema_by_dataset_id(
          prediction_task_schema=schema,
          dataset_id=self.dataset_id,
          prediction_uuid_timestamp=prediction_version_id,
      )
  
imports: from typing import Sequence
  from lightly.openapi_generated.swagger_client.models import PredictionSingleton, PredictionTaskSchema
label_desc: Use image node_id 1 for calling the _PredictionsMixin obj's underlying member method code with example usage: obj.create_or_update_prediction_task_schema(schema, prediction_version_id) without return types