class_docstr: A generic Estimator to train using any algorithm object (with an ``algorithm_arn``).
  
  The Algorithm can be your own, or any Algorithm from AWS
  Marketplace that you have a valid subscription for. This class will perform
  client-side validation on all the inputs.
docstr: Return a ``Transformer`` that uses a SageMaker Model based on the  training job.
  
  It reuses the SageMaker Session and base job name used by the Estimator.
  
  Args:
      instance_count (int): Number of EC2 instances to use.
      instance_type (str): Type of EC2 instance to use, for example,
          'ml.c4.xlarge'.
      strategy (str): The strategy used to decide how to batch records in
          a single request (default: None). Valid values: 'MultiRecord'
          and 'SingleRecord'.
      assemble_with (str): How the output is assembled (default: None).
          Valid values: 'Line' or 'None'.
      output_path (str): S3 location for saving the transform result. If
          not specified, results are stored to a default bucket.
      output_kms_key (str): Optional. KMS key ID for encrypting the
          transform output (default: None).
      accept (str): The accept header passed by the client to
          the inference endpoint. If it is supported by the endpoint,
          it will be the format of the batch transform output.
      env (dict): Environment variables to be set for use during the
          transform job (default: None).
      max_concurrent_transforms (int): The maximum number of HTTP requests
          to be made to each individual transform container at one time.
      max_payload (int): Maximum size of the payload in a single HTTP
          request to the container in MB.
      tags (list[dict]): List of tags for labeling a transform job. If
          none specified, then the tags used for the training job are used
          for the transform job.
      role (str): The ``ExecutionRoleArn`` IAM Role ARN for the ``Model``,
          which is also used during transform jobs. If not specified, the
          role from the Estimator will be used.
      volume_kms_key (str): Optional. KMS key ID for encrypting the volume
          attached to the ML compute instance (default: None).
code: def transformer(
      self,
      instance_count,
      instance_type,
      strategy=None,
      assemble_with=None,
      output_path=None,
      output_kms_key=None,
      accept=None,
      env=None,
      max_concurrent_transforms=None,
      max_payload=None,
      tags=None,
      role=None,
      volume_kms_key=None,
  ):
      """Return a ``Transformer`` that uses a SageMaker Model based on the  training job.
  
      It reuses the SageMaker Session and base job name used by the Estimator.
  
      Args:
          instance_count (int): Number of EC2 instances to use.
          instance_type (str): Type of EC2 instance to use, for example,
              'ml.c4.xlarge'.
          strategy (str): The strategy used to decide how to batch records in
              a single request (default: None). Valid values: 'MultiRecord'
              and 'SingleRecord'.
          assemble_with (str): How the output is assembled (default: None).
              Valid values: 'Line' or 'None'.
          output_path (str): S3 location for saving the transform result. If
              not specified, results are stored to a default bucket.
          output_kms_key (str): Optional. KMS key ID for encrypting the
              transform output (default: None).
          accept (str): The accept header passed by the client to
              the inference endpoint. If it is supported by the endpoint,
              it will be the format of the batch transform output.
          env (dict): Environment variables to be set for use during the
              transform job (default: None).
          max_concurrent_transforms (int): The maximum number of HTTP requests
              to be made to each individual transform container at one time.
          max_payload (int): Maximum size of the payload in a single HTTP
              request to the container in MB.
          tags (list[dict]): List of tags for labeling a transform job. If
              none specified, then the tags used for the training job are used
              for the transform job.
          role (str): The ``ExecutionRoleArn`` IAM Role ARN for the ``Model``,
              which is also used during transform jobs. If not specified, the
              role from the Estimator will be used.
          volume_kms_key (str): Optional. KMS key ID for encrypting the volume
              attached to the ML compute instance (default: None).
      """
      role = role or self.role
  
      if self.latest_training_job is not None:
          model = self.create_model(role=role)
          model._create_sagemaker_model()
          model_name = model.name
          transform_env = {}
          if env is not None:
              transform_env = model.env.copy()
              transform_env.update(env)
          if self._is_marketplace():
              transform_env = None
  
          tags = format_tags(tags) or self.tags
      else:
          raise RuntimeError(
              "No finished training job found associated with this estimator"
          )
  
      return Transformer(
          model_name,
          instance_count,
          instance_type,
          strategy=strategy,
          assemble_with=assemble_with,
          output_path=output_path,
          output_kms_key=output_kms_key,
          accept=accept,
          max_concurrent_transforms=max_concurrent_transforms,
          max_payload=max_payload,
          env=transform_env,
          tags=tags,
          base_transform_job_name=self.base_job_name,
          volume_kms_key=volume_kms_key,
          sagemaker_session=self.sagemaker_session,
      )
  
imports: from __future__ import absolute_import
  from typing import Optional, Union, Dict, List
  import sagemaker
  import sagemaker.parameter
  from sagemaker import vpc_utils
  from sagemaker.deserializers import BytesDeserializer
  from sagemaker.deprecations import removed_kwargs
  from sagemaker.estimator import EstimatorBase
  from sagemaker.inputs import TrainingInput, FileSystemInput
  from sagemaker.serializers import IdentitySerializer
  from sagemaker.transformer import Transformer
  from sagemaker.predictor import Predictor
  from sagemaker.session import Session
  from sagemaker.workflow.entities import PipelineVariable
  from sagemaker.workflow.pipeline_context import runnable_by_pipeline
  from sagemaker.utils import format_tags, Tags
  from sagemaker.workflow import is_pipeline_variable
label_desc: Use image node_id 8 for calling the AlgorithmEstimator obj's underlying member method code with example usage: obj.transformer(instance_count, instance_type, strategy, assemble_with, output_path, output_kms_key, accept, env, max_concurrent_transforms, max_payload, tags, role, volume_kms_key) and returns: Transformer