code: def load_with_torch_fx(
      path: Path, state_dict_name: str = "pruned_state_dict.pt"
  ):
      module_file = path / "module.py"
      with open(module_file, "r") as f:
          module_str = f.read()
      exec(module_str, globals())
      model = eval(FX_MODULE_NAME)()
      model.load_state_dict(torch.load(path / state_dict_name))
      return model
  
file_path: nebuly/optimization/nebullvm/nebullvm/tools/pytorch.py
imports: from pathlib import Path
  from typing import List, Tuple, Optional, Dict, Union, Sequence
  from loguru import logger
  from nebullvm.core.models import Device, DataType, DeviceType, InputInfo
  from nebullvm.optional_modules.torch import torch, DataLoader
  from nebullvm.tools.data import DataManager
  from nebullvm.tools.diffusers import get_default_dynamic_info
label_desc: Use image node_id 2 for calling a global function with example usage: load_with_torch_fx(path, state_dict_name) and returns: model