Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensures weights/ dir exists #51

Conversation

KPLauritzen
Copy link

@KPLauritzen KPLauritzen commented Jun 13, 2020

Allows train.py to be run outside of yolov5/ directory.

Otherwise this requires the user to make a directory called weights/ in the working directory.

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Enhanced training script to ensure weights directory exists.

📊 Key Changes

  • Added a line of code to create the 'weights' directory if it does not exist.

🎯 Purpose & Impact

  • 🛠️ Purpose: Prevents potential errors or crashes that could occur if the 'weights' directory, where model weights are saved during training, is missing.
  • 🔁 Impact: Users experience a more robust and error-proof training process, as the script now automatically handles directory creation.

Allows train.py to be run outside of yolov5/ directory.
@glenn-jocher
Copy link
Member

Good idea, thank you!

@glenn-jocher glenn-jocher merged commit 19e68e8 into ultralytics:master Jun 13, 2020
@alexk-ede alexk-ede mentioned this pull request Sep 5, 2022
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants