Code Monkey home page Code Monkey logo

Comments (11)

ou525 avatar ou525 commented on April 28, 2024 2

@glenn-jocher when I updated the code to No. 16, I started training with pre-training weights, but there was a phenomenon of map 0. Is this normal?
Epoch gpu_mem GIoU obj cls total targets img_size
0/49 6.53G 0.05633 0.03247 0.0106 0.09941 17 608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:10:08<00:00, 5.75s/it]
Class Images Targets P R [email protected] [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [12:07<00:00, 2.14s/it]
all 5.43e+03 2.41e+04 0.494 0.787 0.752 0.406

 Epoch   gpu_mem      GIoU       obj       cls     total   targets  img_size
  1/49     6.73G   0.04195   0.02837  0.002496   0.07282        19       608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:14:47<00:00,  5.95s/it]
           Class      Images     Targets           P           R      [email protected]  [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [25:43<00:00,  4.54s/it]
             all    5.43e+03    2.41e+04           0           0           0           0

 Epoch   gpu_mem      GIoU       obj       cls     total   targets  img_size
  2/49     6.73G   0.04216   0.03074  0.002763   0.07566        16       608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:18:39<00:00,  6.12s/it]
           Class      Images     Targets           P           R      [email protected]  [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [25:51<00:00,  4.56s/it]
             all    5.43e+03    2.41e+04           0           0           0           0

 Epoch   gpu_mem      GIoU       obj       cls     total   targets  img_size
  3/49     6.73G   0.04186    0.0325  0.002924   0.07728        10       608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:15:52<00:00,  6.00s/it]
           Class      Images     Targets           P           R      [email protected]  [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [25:39<00:00,  4.53s/it]
             all    5.43e+03    2.41e+04           0           0           0           0

 Epoch   gpu_mem      GIoU       obj       cls     total   targets  img_size
  4/49     6.73G   0.04029   0.03193  0.002385   0.07461        24       608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:14:47<00:00,  5.95s/it]
           Class      Images     Targets           P           R      [email protected]  [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [25:49<00:00,  4.56s/it]
             all    5.43e+03    2.41e+04           0           0           0           0

 Epoch   gpu_mem      GIoU       obj       cls     total   targets  img_size
  5/49     6.74G   0.03929   0.03121  0.002087   0.07259        92       608:  78%|██████████████████████████████████████████████████████████████▋                 | 1065/1359 [1:45:58<09:14,  1.88s/it]
  5/49     6.74G   0.03914   0.03114  0.002126    0.0724        31       608: 100%|████████████████████████████████████████████████████████████████████████████████| 1359/1359 [2:13:43<00:00,  5.90s/it]
           Class      Images     Targets           P           R      [email protected]  [email protected]:.95: 100%|████████████████████████████████████████████████████████████████████████| 340/340 [25:41<00:00,  4.53s/it]

from yolov5.

github-actions avatar github-actions commented on April 28, 2024

Hello @ou525, thank you for your interest in our work! Please visit our Custom Training Tutorial to get started, and see our Google Colab Notebook, Docker Image, and GCP Quickstart Guide for example environments.

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 model or data training question, please note that Ultralytics does not provide free personal support. As a leader in vision ML and AI, we do offer professional consulting, from simple expert advice up to delivery of fully customized, end-to-end production solutions for our clients, such as:

  • Cloud-based AI surveillance systems operating on hundreds of HD video streams in realtime.
  • Edge AI integrated into custom iOS and Android apps for realtime 30 FPS video inference.
  • Custom data training, hyperparameter evolution, and model exportation to any destination.

For more information please visit https://www.ultralytics.com.

from yolov5.

glenn-jocher avatar glenn-jocher commented on April 28, 2024

@ou525 if your dataset is small, then yes you are strongly recommended to start training from the pretrained checkpoints:

python train.py --cfg yolov5s.yaml --weights yolov5s.pt

from yolov5.

ou525 avatar ou525 commented on April 28, 2024

@glenn-jocher,thank you very much for your work and reply!
There is another problem, I set the training size to 640, the saved train_batch*.jpg is 1280X1280, the boxes are normal, but the test_batch*.jpg is 1280X448, and the boxes in gt.jpg are wrong

from yolov5.

ou525 avatar ou525 commented on April 28, 2024

My dataset has only four categories, which is different from the coco dataset. So can pre-training weights be used? When I training, the error is not compatible with yolov5l.yaml, specify --weights'' or specify a --cfg compatible with yolov5l.pt

from yolov5.

yxNONG avatar yxNONG commented on April 28, 2024

@glenn-jocher the pretrained weight is whether for the Darknet or for the whole yolo network?
if it's for the whole yolo, when i change the num of class, the yolo detect head's shape is supposed to change
in that case, can i still load the pretrained weight to the adjust yolo ?
looking for your reply, thanks

from yolov5.

glenn-jocher avatar glenn-jocher commented on April 28, 2024

@ou525 @yxNONG you can request pretrained weights with train.py such as:
python train.py --cfg c --weights yolov5s.pt

It does not matter how many output classes are specified in yolov5s.yaml. All pretrained layers with matching sizes are loaded.

If you train an 80 class model, then all pretrained layers are loaded. If you train a model with different class counts, then pretrained output layers will not be loaded (because they are not the same shape). All other pretrained layers will be loaded.

For more information on this you can see our PyTorch Hub post:
https://docs.ultralytics.com/yolov5/tutorials/pytorch_hub_model_loading

from yolov5.

glenn-jocher avatar glenn-jocher commented on April 28, 2024

@ou525 train 300 epochs and then post your results.png.

from yolov5.

ou525 avatar ou525 commented on April 28, 2024

@glenn-jocher If training based on pre-training weights still needs so many epochs, if it can not converge quickly, then the role of pre-training weights is not lost?

from yolov5.

glenn-jocher avatar glenn-jocher commented on April 28, 2024

@ou525 if you want to see the effect, then train with and without them, both to 300, and post your results.

from yolov5.

github-actions avatar github-actions commented on April 28, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from yolov5.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.