Hey I am sure you may hear this a lot, but your content is truly amazing. It's very awe-inspiring to see people with such a high level technical knowledge and communication skills making difficult topics very easy to digest. I wish there were more people like you, keep up the excellent work.
Thank you so much for these kind words. Truly happy that you found my content helpful. My technical knowledge isnt that high actually :) but just like everybody else trying to get better little by little. Creating these videos helps me as well, to get a better understanding of topics, as it forces me to ask a lot of "what/how" questions, that I didn't before.
Bro, u have the best explaination about all these metrics and object detection in general but ur chanel won't shown up even when I have search for "object detection explaining ai", I don't know why but I want u to reach to more people may be it's because of that - in ur name... THANKS 4 such quality though :)
Thank you so much for the appreciation. I agree I do need to change the name to something thats unique and more search friendly(have been putting it off for quite some time). I think if you search "object detection explainingai", only then it returns the relevant videos from my channel.
Very good and detailed explanation. I think the Curve shown in the example at @18:55 is wrong since the mAP is always monotonically decreasing due to the prior confidence-based sorting.
Thank You. While the predictions and confidence scores used in the video are hypothetical but its still plausible for the curve to not be monotonically decreasing. Because even after confidence sorting, it could be that a higher confidence detection is a false positive and a lower confidence detection is a true positive. That would first decrease the precision and then increase it. And because of this we do the step of replacing each precision value with the maximum precision value to the right @20:14 , to smooth the zig zag pattern and then the curve is monotonically decreasing. Let me know if that makes sense.
Hey, this was such a great explanation that I'm currently using your code to calculate metrics for my personal detection dataset! However I'm having trouble understanding why you put the misclassification of the human as a false positive @17:14. Isn't this supposed to be a false negative since the detector failed to give it a positive label when it had a positive ground truth? I also ran your github code with 101 pt interpolation and am also seeing this similar mix-up where i'm getting an AP of 1.0 for a class which has 0 false negatives but some false positives. Same thing applies, I would expect the recall to be 1.0 but the precision to be
Hello, Sure let me try to clarify a bit on this. All the predictions that are made by the model are positive predictions. Because thats where the model thinks an object is present. So all predictions(including the human example) can only be either true or false positive. And not false negative. Only locations where ground truth object instances are present, can be marked as false negative(if that is an object our model missed). The human detection you mentioned has a confidence of 0.9. After this human example, we cant increase our false negative, because what if there is a lower confidence prediction by the model which has an IOU > our threshold(which means we ultimately ended up correctly predicting the gt object). So firstly, we can only decide false negatives after we have iterated over all predictions. Secondly, imagine this scenario, where we have just one ground truth human object and we have 50 predictions(all of them close to ground truth but not passing our threshold). Then if you start marking all of them as false negative, we are going to have 50 false negatives, but there is only one ground truth object, so the maximum value of false negative can only be 1 right. Hence the way we compute false negative, is which of the ground truth object remained unmatched at the end after iterating through all predictions. Please let me know if my clarification still left some doubts regarding this.
Thank You! That is just for ensuring the iou method never ends up doing a division by 0, like say in some degenerate case where bounding box area is zero(of both gt and prediction). That just makes the iou computation numerically stable no matter what the predicted and ground truth box is.
I am really sorry for the late reply. Had thought to provide this code together with an object detection implementation so that one can clearly understand how to use them. But haven't been able to get to that yet. For now, I have pushed the code for this video here - github.com/explainingai-code/DetectionUtils/blob/main/compute_ap.py with comments on what the map computation method is expecting as input and how to create that.
*Github Implementation* - github.com/explainingai-code/DetectionUtils/blob/main/compute_ap.py
A lecture where every single word is carefully chosen!
HUGE EFFORT AND EXCELLENT LECTURE!
KEEP IT UP!
Thank you for this appreciation and your support :)
Hey I am sure you may hear this a lot, but your content is truly amazing. It's very awe-inspiring to see people with such a high level technical knowledge and communication skills making difficult topics very easy to digest. I wish there were more people like you, keep up the excellent work.
Thank you so much for these kind words. Truly happy that you found my content helpful.
My technical knowledge isnt that high actually :) but just like everybody else trying to get better little by little.
Creating these videos helps me as well, to get a better understanding of topics, as it forces me to ask a lot of "what/how" questions, that I didn't before.
The amount of effort you put in explaining these topics is just remarkable.
Thank You :)
It is the best lecture on object detection and metrics that I have ever seen, thanks a lot❤
Thank you for your kind words and am glad that the video ended up being of help to you.
Bro, u have the best explaination about all these metrics and object detection in general but ur chanel won't shown up even when I have search for "object detection explaining ai", I don't know why but I want u to reach to more people may be it's because of that - in ur name...
THANKS 4 such quality though :)
Thank you so much for the appreciation. I agree I do need to change the name to something thats unique and more search friendly(have been putting it off for quite some time). I think if you search "object detection explainingai", only then it returns the relevant videos from my channel.
Very good and detailed explanation. I think the Curve shown in the example at @18:55 is wrong since the mAP is always monotonically decreasing due to the prior confidence-based sorting.
Thank You. While the predictions and confidence scores used in the video are hypothetical but its still plausible for the curve to not be monotonically decreasing.
Because even after confidence sorting, it could be that a higher confidence detection is a false positive and a lower confidence detection is a true positive. That would first decrease the precision and then increase it.
And because of this we do the step of replacing each precision value with the maximum precision value to the right @20:14 , to smooth the zig zag pattern and then the curve is monotonically decreasing.
Let me know if that makes sense.
loved the super simplified code and super simplified explanation
Thank You!
Thanks!
Very Nicely Explained! Keep the good work going 😁👍
your explanation is very clean thanx
great explanation, keep up the good work 💯
Thank You!
Nice tutorial
Hey, this was such a great explanation that I'm currently using your code to calculate metrics for my personal detection dataset! However I'm having trouble understanding why you put the misclassification of the human as a false positive @17:14. Isn't this supposed to be a false negative since the detector failed to give it a positive label when it had a positive ground truth? I also ran your github code with 101 pt interpolation and am also seeing this similar mix-up where i'm getting an AP of 1.0 for a class which has 0 false negatives but some false positives. Same thing applies, I would expect the recall to be 1.0 but the precision to be
Hello, Sure let me try to clarify a bit on this.
All the predictions that are made by the model are positive predictions. Because thats where the model thinks an object is present. So all predictions(including the human example) can only be either true or false positive. And not false negative. Only locations where ground truth object instances are present, can be marked as false negative(if that is an object our model missed).
The human detection you mentioned has a confidence of 0.9. After this human example, we cant increase our false negative, because what if there is a lower confidence prediction by the model which has an IOU > our threshold(which means we ultimately ended up correctly predicting the gt object). So firstly, we can only decide false negatives after we have iterated over all predictions.
Secondly, imagine this scenario, where we have just one ground truth human object and we have 50 predictions(all of them close to ground truth but not passing our threshold). Then if you start marking all of them as false negative, we are going to have 50 false negatives, but there is only one ground truth object, so the maximum value of false negative can only be 1 right.
Hence the way we compute false negative, is which of the ground truth object remained unmatched at the end after iterating through all predictions.
Please let me know if my clarification still left some doubts regarding this.
Great video, but why do you add 1E-6 when calculating your IOU?
Thank You! That is just for ensuring the iou method never ends up doing a division by 0, like say in some degenerate case where bounding box area is zero(of both gt and prediction). That just makes the iou computation numerically stable no matter what the predicted and ground truth box is.
great video!
Thank You!
can you share the code, please?
I am really sorry for the late reply. Had thought to provide this code together with an object detection implementation so that one can clearly understand how to use them.
But haven't been able to get to that yet.
For now, I have pushed the code for this video here - github.com/explainingai-code/DetectionUtils/blob/main/compute_ap.py
with comments on what the map computation method is expecting as input and how to create that.