aws / aws/amazon-sagemaker-examples
[Bug Report] pytorch_torchvision_neo.ipynb deploy model fails
- Dominant language
- Jupyter Notebook
- Stars
- 11k
- Forks
- 7k
- Avg merge
- 8h 29m
- Merged PRs (30d)
- 8
Description
**Link to the notebook**
[Link to the notebook.](https://github.com/aws/amazon-sagemaker-examples/blob/main/sagemaker_neo_compilation_jobs/pytorch_torchvision/pytorch_torchvision_neo.ipynb)
**Describe the bug**
the step "Deploy the model" fails with "FileNotFoundError: [Errno 2] No such file or directory: 'code'"
**To reproduce**
Use conda_pytorch_p38 kernel (the p36 is no longer available), everything else I left as it was.
I assume the "no such file or directory: 'code'" is based on the fact that in model.tar.gz, no code/ folder was added, only the pure model.pth file. Based on what I read in https://sagemaker.readthedocs.io/en/stable/frameworks/pytorch/using_pytorch.html#model-directory-structure , the pyTorch versions 1.2 and higher expect a code/ folder in the .tar.gz file.
**Logs**
If applicable, add logs to help explain your problem.
You may also attach an `.ipynb` file to this issue if it includes relevant logs or output.
Contributor guide
Research direction
Open sagemaker_neo_compilation_jobs/pytorch_torchvision/pytorch_torchvision_neo.ipynb and run it with the conda_pytorch_p38 kernel, focusing first on the “Deploy the model” step. Inspect the generated model.tar.gz and its model.pth and code/ contents. Done means deployment completes without the FileNotFoundError for “code”.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, jupyter-notebook, pytorch
- Domain
- cloud, machine-learning
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100