class_docstr: An GluonTS SageMaker ``Model`` that can be deployed to a SageMaker
  ``Endpoint``.
docstr: Initialize a GluonTSModel.
  
  Parameters
  ----------
  model_data:
      The S3 location of a SageMaker model data ``.tar.gz`` file.
  role:
      An AWS IAM role (either name or full ARN). The Amazon
      SageMaker training jobs and APIs that create Amazon SageMaker
      endpoints use this role to access training data and model
      artifacts. After the endpoint is created, the inference code
      might use the IAM role, if it needs to access an AWS resource.
  entry_point:
      Path (absolute or relative) to the Python source
      file which should be executed as the entry point to model
      hosting. This should be compatible with Python 3.6.
  image:
      A Docker image URI (default: None).
  framework_version:
      GluonTS version you want to use for executing your model training code.
  predictor_cls:
      A function to call to create a predictor with an endpoint name and
      SageMaker ``Session``. If specified, ``deploy()`` returns the
      result of invoking this function on the created endpoint name.
  model_server_workers:
      Optional. The number of worker processes used by the inference server. If None,
      server will use one worker per vCPU.
  **kwargs:
      Keyword arguments passed to the ``FrameworkModel`` initializer.
docstr_tok: ["Initialize","a","GluonTSModel",".","Parameters","--","--","--","--","--","model_data",":","The","S3","location","of","a","SageMaker","model","data","``",".tar.gz","``","file",".","role",":","An","AWS","IAM","role","(","either","name","or","full","ARN",")",".","The","Amazon","SageMaker","training","jobs","and","APIs","that","create","Amazon","SageMaker","endpoints","use","this","role","to","access","training","data","and","model","artifacts",".","After","the","endpoint","is","created",",","the","inference","code","might","use","the","IAM","role",",","if","it","needs","to","access","an","AWS","resource",".","entry_point",":","Path","(","absolute","or","relative",")","to","the","Python","source","file","which","should","be","executed","as","the","entry","point","to","model","hosting",".","This","should","be","compatible","with","Python","3.6.","image",":","A","Docker","image","URI","(","default",":","None",")",".","framework_version",":","GluonTS","version","you","want","to","use","for","executing","your","model","training","code",".","predictor_cls",":","A","function","to","call","to","create","a","predictor","with","an","endpoint","name","and","SageMaker","``","Session","``",".","If","specified",",","``","deploy","(",")","``","returns","the","result","of","invoking","this","function","on","the","created","endpoint","name",".","model_server_workers",":","Optional",".","The","number","of","worker","processes","used","by","the","inference","server",".","If","None",",","server","will","use","one","worker","per","vCPU",".","*","*","kwargs",":","Keyword","arguments","passed","to","the","``","FrameworkModel","``","initializer","."]
code: def __init__(
      self,
      model_data,
      role,
      entry_point,
      image: str = None,
      framework_version: str = GLUONTS_VERSION,
      predictor_cls=GluonTSPredictor,  # (callable[str, session.Session])
      model_server_workers: int = None,
      **kwargs,
  ):
      """
      Initialize a GluonTSModel.
  
      Parameters
      ----------
      model_data:
          The S3 location of a SageMaker model data ``.tar.gz`` file.
      role:
          An AWS IAM role (either name or full ARN). The Amazon
          SageMaker training jobs and APIs that create Amazon SageMaker
          endpoints use this role to access training data and model
          artifacts. After the endpoint is created, the inference code
          might use the IAM role, if it needs to access an AWS resource.
      entry_point:
          Path (absolute or relative) to the Python source
          file which should be executed as the entry point to model
          hosting. This should be compatible with Python 3.6.
      image:
          A Docker image URI (default: None).
      framework_version:
          GluonTS version you want to use for executing your model training code.
      predictor_cls:
          A function to call to create a predictor with an endpoint name and
          SageMaker ``Session``. If specified, ``deploy()`` returns the
          result of invoking this function on the created endpoint name.
      model_server_workers:
          Optional. The number of worker processes used by the inference server. If None,
          server will use one worker per vCPU.
      **kwargs:
          Keyword arguments passed to the ``FrameworkModel`` initializer.
      """
  
      super().__init__(
          model_data,
          image,
          role,
          entry_point,
          predictor_cls=predictor_cls,
          **kwargs,
      )
  
      self.framework_version = framework_version
      self.model_server_workers = model_server_workers
  
file_path: gluonts/src/gluonts/nursery/sagemaker_sdk/model.py
imports: import logging
  from typing import Dict
  import sagemaker
  from pkg_resources import parse_version
  from sagemaker import session
  from sagemaker.fw_utils import model_code_key_prefix
  from sagemaker.model import MODEL_SERVER_WORKERS_PARAM_NAME, FrameworkModel
  from sagemaker.predictor import RealTimePredictor, json_deserializer, json_serializer
  from .defaults import FRAMEWORK_NAME, GLUONTS_VERSION, LOWEST_MMS_VERSION
label_desc: Use image node_id 1 to create a new GluonTSModel object from inherited base classes: FrameworkModel with example: obj = GluonTSModel(model_data, role, entry_point, image, framework_version, predictor_cls, model_server_workers)