-
-
Notifications
You must be signed in to change notification settings - Fork 16.1k
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
YOLOv5 val.py report different result by different run #11868
Comments
@mahilaMoghadami hi, The YOLOv5 Regarding the missing images in the prediction results, it is possible that those images did not meet the confidence threshold ( If the issue persists, please provide more details such as the size of your dataset, the number of missing images, and any additional information that might help us reproduce the problem. Please keep in mind that the YOLOv5 repository is a community-driven project, and your feedback and contributions are valuable to improve its functionality. Thank you for using YOLOv5. Best regards, |
Thank you @glenn-jocher Even by setting different confidence thresholds, the problem persists. Im using VisDrone dataset. the number of images in the val set for evaluation is 548 which is loaded correctly. but when I checked JSON coco prediction results and print number of unique image_ids in JSON file, I understood that there is a gap between the number of loaded image and number of unique image_ids in JSON file. Thank you for your response. |
Hi @mahilaMoghadami, I apologize for the confusion. If you have set different confidence thresholds but the issue persists, it is indeed unusual that there is a gap between the number of loaded images and the number of unique image IDs in the JSON file. In order to investigate further, could you please provide more information about how you generated your JSON coco prediction results? Specifically, the steps you followed and any custom code or modifications you made to the YOLOv5 codebase. Additionally, please ensure that your dataset is properly formatted and that the images missing in the prediction results are present in the evaluation set. Thank you for bringing this to our attention. We will do our best to assist you further once we have more information. Kind regards, |
Thank youI used '--save json' in val. Py as arguman to create prediction coco result which is prepared in YOLO completely and no additional or custome code.
|
Hi @mahilaMoghadami, Thank you for providing the additional information. Based on your response, it appears that you are using the When using this argument, the script should save the predictions in COCO format for evaluation purposes. However, if there is a discrepancy between the number of loaded images and the number of unique image IDs in the generated JSON file, it could indicate an issue with the script. To further investigate this, it would be helpful if you could provide the exact command you are running for the validation, along with any relevant details such as the version of YOLOv5 you are using and the specific dataset or dataset format you are working with. By providing this information, we will be able to better assist you in identifying the cause of the missing images in the COCO prediction results. Thank you for your patience, and we look forward to helping you resolve this issue. Kind regards, |
thanks for your response. I use YOLOv5s and VisDrone is my dataset. In addition, as I checked, even I use --save-txt for saving prediction result, txt files number isn't matched with image numbers. |
@mahilaMoghadami thanks for providing the specific command you're using for validation and the details of your dataset. The fact that the number of generated JSON files doesn't match the number of loaded images suggests a potential issue with the To investigate further, could you please clarify if you have performed any preprocessing steps on your dataset, such as filtering or removing certain images? Additionally, please ensure that your dataset is correctly structured, following the required format for YOLOv5. If you haven't made any modifications to the YOLOv5 codebase or preprocessing steps, it may be helpful to double-check your dataset to ensure it contains the expected number of images and corresponding annotation files. If the issue persists, please provide more details about the VisDrone dataset, such as its composition and any preprocessing steps that you have applied. Thank you for your patience, and we'll do our best to assist you in resolving this discrepancy. Regards, |
@mahilaMoghadami hello, Thank you for providing the additional information regarding your dataset and the command you used to generate the predicted output. Based on the images you shared, it appears that the number of generated text files does not match the number of loaded images. This discrepancy could be a result of an issue within the To further investigate and resolve this issue, I recommend opening a new GitHub issue on the YOLOv5 repository. Please include all relevant details, such as the specific command you used, the version of YOLOv5 you are using, and any other relevant information about your dataset. By opening a new issue, the YOLOv5 community and developers can help assess and address the problem you are facing. Thank you for bringing this to our attention, and we appreciate your patience. Regards, |
👋 Hello there! We wanted to give you a friendly reminder that this issue has not had any recent activity and may be closed soon, but don't worry - you can always reopen it if needed. If you still have any questions or concerns, please feel free to let us know how we can help. For additional resources and information, please see the links below:
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 YOLO 🚀 and Vision AI ⭐ |
Search before asking
Question
Hello
I get different results by running val.py with equal config (different output with each run).
this is my config:
python val.py --data 'data/VisDrone.yaml' --weights '/yolov5/runs/train/FineTune50/weights/best.pt' --img 1088 --conf-thres 0.3 --task test --save-json
also, as I checked ,I understood that some images where missed in coco prediction result (best-prediction.json file)
I understood that by printing number of unique image_ids in json predicted output file where was not equal to number of images for evaluation.
Appreciate for help me to understand.
Thank you
Additional
No response
The text was updated successfully, but these errors were encountered: