code: def test_estimator_deploy(sagemaker_session):
      container_log_level = '"logging.INFO"'
      source_dir = "s3://mybucket/source"
      custom_image = "custom:1.0"
      tf = TensorFlow(
          entry_point="script.py",
          role=ROLE,
          sagemaker_session=sagemaker_session,
          instance_count=INSTANCE_COUNT,
          instance_type=INSTANCE_TYPE,
          image_uri=custom_image,
          container_log_level=container_log_level,
          base_job_name="job",
          source_dir=source_dir,
      )
  
      job_name = "doing something"
      tf.fit(inputs="s3://mybucket/train", job_name=job_name)
      predictor = tf.deploy(
          INSTANCE_COUNT, INSTANCE_TYPE, endpoint_name="endpoint"
      )
      assert isinstance(predictor, TensorFlowPredictor)
  
imports: from __future__ import absolute_import
  import io
  import json
  import logging
  import mock
  import pytest
  from mock import Mock, patch, ANY
  from sagemaker.serializers import CSVSerializer, IdentitySerializer
  from sagemaker.tensorflow import TensorFlow, TensorFlowModel, TensorFlowPredictor
label_desc: Use image node_id 12 for calling a global function with example usage: test_estimator_deploy(sagemaker_session) without return types