yolov5
yolov5 copied to clipboard
YOLOv5 Classification Success??
Search before asking
- [X] I have searched the YOLOv5 issues and discussions and found no similar questions.
Question
Hey! How can i increase success of YOLOv5 classification model?
Additional
No response
👋 Hello @salihai, thank you for your interest in YOLOv5 🚀! Please visit our ⭐️ Tutorials to get started, where you can find quickstart guides for simple tasks like Custom Data Training all the way to advanced concepts like Hyperparameter Evolution.
If this is a 🐛 Bug Report, please provide screenshots and minimum viable code to reproduce your issue, otherwise we can not help you.
If this is a custom training ❓ Question, please provide as much information as possible, including dataset images, training logs, screenshots, and a public link to online W&B logging if available.
For business inquiries or professional support requests please visit https://ultralytics.com or email [email protected].
Requirements
Python>=3.7.0 with all requirements.txt installed including PyTorch>=1.7. To get started:
git clone https://github.com/ultralytics/yolov5 # clone
cd yolov5
pip install -r requirements.txt # install
Environments
YOLOv5 may be run in any of the following up-to-date verified environments (with all dependencies including CUDA/CUDNN, Python and PyTorch preinstalled):
-
Google Colab and Kaggle notebooks with free GPU:
- Google Cloud Deep Learning VM. See GCP Quickstart Guide
- Amazon Deep Learning AMI. See AWS Quickstart Guide
-
Docker Image. See Docker Quickstart Guide
Status
If this badge is green, all YOLOv5 GitHub Actions Continuous Integration (CI) tests are currently passing. CI tests verify correct operation of YOLOv5 training (train.py), validation (val.py), inference (detect.py) and export (export.py) on macOS, Windows, and Ubuntu every 24 hours and on every commit.
@salihai hmm, you might want to try different augmentation strategies here (make sure albumentations is installed) https://github.com/ultralytics/yolov5/blob/0b724c5b851b32bb3a8fbfab3cc2d68f93b4661e/utils/augmentations.py#L306-L339
or you could also try loading different torchvision architectures like resnet, efficientnet, etc., i.e.:
python classify/train.py --model efficientnet_b2
@glenn-jocher Okey thank you. I'll try and inform you about the results.
How to use this function? I thought by doing data augmentation, you only change .yaml file yolov5/data/hyps/hyp.scratch-low.yaml
@frabob2017 classify_albumentations function is in yolov5/utils/augmentations.py file. You can use it by changing the parameters from here.
@frabob2017 classify_albumentations function is in yolov5/utils/augmentations.py file. You can use it by changing the parameters from here.
it is a great learning platform for Yolo algorithm.
@glenn-jocher Hello again! There is one more thing I wonder about the question I asked earlier. During my summer internship, I was asked to perform a Yolo classification operation using the publicly available CheXpert dataset. I tried different augmentation strategies and different torchvision architectures with your suggestion here. But I couldn't find any solution that increased my accuracy. I also preprocessed the data in different ways, but it still didn't work. Does anyone have any work or knowledge of this dataset? How can I perform YOLOv5 classification on this data? Also what is the difference between top1_acc and top5_acc?
@salihai if it's a standard classification format (directories with images), then just pass the dataset directory for training, i.e.:
python classify/train.py --data path/to/dataset
@glenn-jocher Yes, I already know this process. My problem is to find a solution to why the accuracy of the model is not increasing. :(((
@salihai then you have to experiment with different models, training settings, hyps, etc.
👋 Hello, this issue has been automatically marked as stale because it has not had recent activity. Please note it will be closed if no further activity occurs.
Access additional YOLOv5 🚀 resources:
- Wiki – https://github.com/ultralytics/yolov5/wiki
- Tutorials – https://docs.ultralytics.com/yolov5
- Docs – https://docs.ultralytics.com
Access additional Ultralytics ⚡ resources:
- Ultralytics HUB – https://ultralytics.com/hub
- Vision API – https://ultralytics.com/yolov5
- About Us – https://ultralytics.com/about
- Join Our Team – https://ultralytics.com/work
- Contact Us – https://ultralytics.com/contact
Feel free to inform us of any other issues you discover or feature requests that come to mind in the future. Pull Requests (PRs) are also always welcomed!
Thank you for your contributions to YOLOv5 🚀 and Vision AI ⭐!