code: def transform_step(pipeline_session):
      transformer = Transformer(
          model_name="my-model",
          instance_type="ml.m5.xlarge",
          instance_count=1,
          output_path="s3://my-bucket/my-output-path",
          sagemaker_session=pipeline_session,
      )
      transform_inputs = TransformInput(data="s3://my-bucket/my-data")
      step_args = transformer.transform(
          data=transform_inputs.data,
          data_type=transform_inputs.data_type,
          content_type=transform_inputs.content_type,
          compression_type=transform_inputs.compression_type,
          split_type=transform_inputs.split_type,
          input_filter=transform_inputs.input_filter,
          output_filter=transform_inputs.output_filter,
          join_source=transform_inputs.join_source,
          model_client_config=transform_inputs.model_client_config,
      )
      return TransformStep(
          name="MyTransformStep",
          step_args=step_args,
      )
  
imports: from __future__ import absolute_import
  import os
  import pytest
  from mock import Mock, patch, PropertyMock
  from botocore.exceptions import ClientError
  from mock.mock import MagicMock
  from sagemaker.estimator import Estimator
  from sagemaker.inputs import TrainingInput
  from sagemaker.debugger import ProfilerConfig
  from sagemaker.processing import ProcessingInput, ProcessingOutput, Processor
  from sagemaker.remote_function.core.stored_function import RESULTS_FOLDER
  from sagemaker.remote_function.job import SCRIPT_AND_DEPENDENCIES_CHANNEL_NAME, RUNTIME_SCRIPTS_CHANNEL_NAME
  from sagemaker.s3_utils import s3_path_join
  from sagemaker.transformer import Transformer
  from sagemaker.workflow.condition_step import ConditionStep
  from sagemaker.workflow.conditions import ConditionEquals, ConditionGreaterThan, ConditionGreaterThanOrEqualTo, ConditionIn, ConditionLessThan, ConditionLessThanOrEqualTo, ConditionNot, ConditionOr
  from sagemaker.workflow.fail_step import FailStep
  from sagemaker.workflow.function_step import step
  from sagemaker.workflow.parameters import ParameterInteger, ParameterString
  from sagemaker.workflow.pipeline import Pipeline
  from sagemaker.workflow.pipeline_context import PipelineSession
  from sagemaker.workflow.step_outputs import get_step
  from sagemaker.workflow.steps import ProcessingStep, TrainingStep, TransformStep, TransformInput, StepTypeEnum
  from sagemaker.local.pipeline import _ConditionStepExecutor, _FailStepExecutor, _ProcessingStepExecutor, _StepExecutorFactory, _TrainingStepExecutor, _TransformStepExecutor, _CreateModelStepExecutor, LocalPipelineExecutor, StepExecutionException
  from sagemaker.local.entities import _LocalExecutionStatus, _LocalPipelineExecution
  from sagemaker.workflow.execution_variables import ExecutionVariables
  from sagemaker.workflow.functions import Join, JsonGet, PropertyFile
  from sagemaker.local.local_session import LocalSession
  from tests.unit.sagemaker.workflow.helpers import CustomStep
  from tests.unit import DATA_DIR
label_desc: Use image node_id 8 for calling a global function with example usage: transform_step(pipeline_session) and returns: TransformStep