-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
When I try to load the model using the model.pt file provided with the MONAI Model Zoo, I get the following error.

net = torch.jit.load(env_dict["model_path"]).to(device)
File "/database/home/tangchi/.conda/envs/medsam/lib/python3.10/site-packages/torch/jit/_serialization.py", line 163, in load
cpp_module = torch._C.import_ir_module(cu, os.fspath(f), map_location, _extra_files, _restore_shapes) # type: ignore[call-arg]
RuntimeError: PytorchStreamReader failed locating file constants.pkl: file not found
config:
MONAI version: 1.3.2
Numpy version: 1.26.3
Pytorch version: 2.4.0+cu118
MONAI flags: HAS_EXT = False, USE_COMPILED = False, USE_META_DICT = False
MONAI rev id: 59a7211
MONAI file: /database/home//.local/lib/python3.10/site-packages/monai/init.py
Optional dependencies:
Pytorch Ignite version: 0.4.11
ITK version: 5.4.0
Nibabel version: 5.2.0
scikit-image version: 0.23.1
scipy version: 1.14.0
Pillow version: 10.2.0
Tensorboard version: 2.17.1
gdown version: 5.2.0
TorchVision version: 0.19.0+cu118
tqdm version: 4.66.4
lmdb version: 1.5.1
psutil version: 5.9.6
pandas version: 2.2.2
einops version: 0.8.0
transformers version: 4.40.2
mlflow version: 2.15.1
pynrrd version: 1.0.0
clearml version: 1.16.4