code: def created_base_model(sagemaker_session, cpu_instance_type):
      model_data = sagemaker_session.upload_data(path=IR_SKLEARN_MODEL)
      region = sagemaker_session._region_name
      image_uri = image_uris.retrieve(
          framework="sklearn",
          region=region,
          version="1.0-1",
          image_scope="inference",
      )
  
      iam_client = sagemaker_session.boto_session.client("iam")
      role_arn = iam_client.get_role(RoleName="SageMakerRole")["Role"][
          "Arn"
      ]
  
      model = Model(
          model_data=model_data,
          role=role_arn,
          entry_point=IR_SKLEARN_ENTRY_POINT,
          image_uri=image_uri,
          sagemaker_session=sagemaker_session,
      )
  
      model.create(instance_type=cpu_instance_type)
  
      return model
  
imports: from __future__ import absolute_import
  import os
  import time
  import pytest
  from botocore.exceptions import ClientError
  from sagemaker import image_uris
  from sagemaker.model import Model
  from sagemaker.sklearn.model import SKLearnModel, SKLearnPredictor
  from sagemaker.utils import unique_name_from_base
  from tests.integ import DATA_DIR
  from tests.integ.timeout import timeout
  import pandas
  from sagemaker.inference_recommender.inference_recommender_mixin import Phase, ModelLatencyThreshold
  from sagemaker.parameter import CategoricalParameter
  import logging
label_desc: Use image node_id 7 for calling a global function with example usage: created_base_model(sagemaker_session, cpu_instance_type) and returns: model