Failed to Download the Code Directory
Symptom
The code directory fails to be downloaded during training job running, and the following error message is displayed. See Figure 1.
ERROR: modelarts-downloader.py: Get object key failed: 'Contents'
Possible Cause
The code directory specified during training job creation does not exist. As a result, the training fails.
Solution
Check whether the code directory specified during training job creation, that is, the OBS bucket path, is correct based on the error cause. There are two methods to check whether it exists.
- Log in to the OBS console using the current account, and search for the OBS buckets, folders, and files in the path to check whether the code directory exists.
- Using APIs to check whether the directory exists: Run the following command in code to check whether the directory exists:
import moxing as mox mox.file.exists('obs://obs-test/ModelArts/examples/')
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot