code: def create_mock_modules(name, doc, file):
      m = ModuleType(name, doc)
      m.__file__ = file
      return m
  
file_path: sagemaker-python-sdk/tests/unit/sagemaker/serve/detector/test_pickle_dependencies.py
imports: from __future__ import absolute_import
  from sagemaker.serve.detector.pickle_dependencies import get_requirements_for_pkl_file
  import boto3
  import json
  import io
  import sys
  import subprocess
  from mock import MagicMock, mock_open, patch, call
  from types import ModuleType
  import logging
label_desc: Use image node_id 1 for calling a global function with example usage: create_mock_modules(name, doc, file) and returns: m