How Do I Check Whether a Folder Copy Is Complete During Job Training in ModelArts?
In the script for the training job boot file, run the following commands to obtain the sizes of the source folder and the copy. Then determine whether folder is copied based on the command output.
import moxing as mox mox.file.get_size('obs://bucket_name/obs_file',recursive=True)
get_size indicates the size of the file or folder to be obtained. recursive=True indicates that the type is folder. True indicates that the type is folder, and False indicates that the type is file.
If the command output is consistent, the folder is copied. If the command output is inconsistent, the folder is not copied.
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