https://github.com/jahongir7174/yolov5-pt
YOLOv5 implementation using PyTorch
https://github.com/jahongir7174/yolov5-pt
object-detection pytorch testing training yolov5
Last synced: 5 months ago
JSON representation
YOLOv5 implementation using PyTorch
- Host: GitHub
- URL: https://github.com/jahongir7174/yolov5-pt
- Owner: jahongir7174
- Created: 2021-01-11T15:21:27.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-08-22T06:18:04.000Z (about 2 years ago)
- Last Synced: 2025-03-31T18:51:44.661Z (7 months ago)
- Topics: object-detection, pytorch, testing, training, yolov5
- Language: Python
- Homepage:
- Size: 9.99 MB
- Stars: 5
- Watchers: 0
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
YOLOv5 implementation using PyTorch
### Installation
```
conda create -n YOLO python=3.8
conda activate YOLO
conda install pytorch torchvision torchaudio cudatoolkit=10.2 -c pytorch-lts
pip install opencv-python==4.5.5.64
pip install PyYAML
pip install tqdm
```### Train
* Configure your dataset path in `main.py` for training
* Run `bash main.sh $ --train` for training, `$` is number of GPUs### Test
* Configure your dataset path in `main.py` for testing
* Run `python main.py --test` for testing### Results
| Version | Epochs | Box mAP | Download |
|:-------:|:------:|--------:|------------------------------------------------------------------------------------:|
| v5_n | 600 | 28.0 | [model](./weights/best.pt) |
| v5_n* | 300 | 27.6 | [model](https://github.com/jahongir7174/YOLOv5-pt/releases/download/v0.0.1/v5_n.pt) |
| v5_s* | 300 | 37.1 | [model](https://github.com/jahongir7174/YOLOv5-pt/releases/download/v0.0.1/v5_s.pt) |
| v5_m* | 300 | 44.7 | [model](https://github.com/jahongir7174/YOLOv5-pt/releases/download/v0.0.1/v5_m.pt) |
| v5_l* | 300 | 48.4 | [model](https://github.com/jahongir7174/YOLOv5-pt/releases/download/v0.0.1/v5_l.pt) |
| v5_x* | 300 | 50.0 | [model](https://github.com/jahongir7174/YOLOv5-pt/releases/download/v0.0.1/v5_x.pt) |* `*` means that weights are ported from original repo, see reference
* To reproduce results, run `bash main.sh 2 --train --epochs 600`, see `steps.csv` for training log### Dataset structure
├── COCO
├── images
├── train2017
├── 1111.jpg
├── 2222.jpg
├── val2017
├── 1111.jpg
├── 2222.jpg
├── labels
├── train2017
├── 1111.txt
├── 2222.txt
├── val2017
├── 1111.txt
├── 2222.txt#### Reference
* https://github.com/ultralytics/yolov5