code: def test_create_model_with_custom_image(
      name_from_base, sagemaker_session
  ):
      container_log_level = '"logging.INFO"'
      source_dir = "s3://mybucket/source"
      image = "selfdrivingcars:9000"
      rl = RLEstimator(
          entry_point=SCRIPT_PATH,
          role=ROLE,
          sagemaker_session=sagemaker_session,
          instance_count=INSTANCE_COUNT,
          instance_type=INSTANCE_TYPE,
          image_uri=image,
          container_log_level=container_log_level,
          source_dir=source_dir,
      )
  
      job_name = "new_name"
      rl.fit(job_name=job_name)
  
      model_name = "model_name"
      name_from_base.return_value = model_name
      new_entry_point = "deploy_script.py"
      model = rl.create_model(entry_point=new_entry_point)
  
      assert model.sagemaker_session == sagemaker_session
      assert model.image_uri == image
      assert model.entry_point == new_entry_point
      assert model.role == ROLE
      assert model.name == model_name
      assert model.container_log_level == container_log_level
      assert model.source_dir == source_dir
  
      name_from_base.assert_called_with("selfdrivingcars")
  
imports: from __future__ import absolute_import
  import json
  import logging
  import os
  import pytest
  from mock import MagicMock, Mock, patch
  from sagemaker.mxnet import MXNetModel, MXNetPredictor
  from sagemaker.rl import RLEstimator, RLFramework, RLToolkit, TOOLKIT_FRAMEWORK_VERSION_MAP
  from sagemaker.session_settings import SessionSettings
  from sagemaker.tensorflow import TensorFlowModel, TensorFlowPredictor
label_desc: Use image node_id 8 for calling a global function with example usage: test_create_model_with_custom_image(name_from_base, sagemaker_session) without return types