Conversation
|
Hi @AlexanderChaptykov , thanks for your comment. Yes that would be nice, but I need a short time to add a few commits beforehand. |
|
@vfdev-5 , finally It's ready to get reviewed. |
i.e. ObjectDetectionMap and its dependencies
Removed allow_multiple... Renamed average_operand Renamed _measure_recall... to _compute_recall...
Docs has some nasty errors
Removed generic detection logics. Just that of the COCO is remained Tests are updated
9a45edc to
0444933
Compare
|
Hi @vfdev-5 , finally this seems to be ready for review. failure reasons:
|
|
@sadra-barikbin sounds great!
Let's do the following: # precision_integrand = precision.flip(-1).cummax(dim=-1).values.flip(-1)
if precision.device.type == "mps":
# Manual fallback to CPU if precision is on MPS due to the error:
# NotImplementedError: The operator 'aten::_cummax_helper' is not currently implemented for the MPS device
device = precision.device
precision_integrand = precision.flip(-1).cpu()
precision_integrand = precision_integrand.cummax(dim=-1).values
precision_integrand = precision_integrand.to(device=device).flip(-1)
else:
precision_integrand = precision.flip(-1).cummax(dim=-1).values.flip(-1)
I haven't seen that previously. If we have large tensors in the test, we can skip those tests on MPS device. |
vfdev-5
left a comment
There was a problem hiding this comment.
Few comments.
Thanks a lot for still working on this PR, Sadra!
ignite/metrics/vision/object_detection_average_precision_recall.py
Outdated
Show resolved
Hide resolved
ignite/metrics/vision/object_detection_average_precision_recall.py
Outdated
Show resolved
Hide resolved
vfdev-5
left a comment
There was a problem hiding this comment.
Few minor updates and let's try to merge this great PR, @sadra-barikbin !
Thanks a lot for finally making this possible!
| self, | ||
| iou_thresholds: Optional[Union[Sequence[float], torch.Tensor]] = None, | ||
| rec_thresholds: Optional[Union[Sequence[float], torch.Tensor]] = None, | ||
| num_classes: int = 91, |
There was a problem hiding this comment.
Should not this match MS Coco number of classes: 80 or 81
There was a problem hiding this comment.
Yes, you're right. The model used in tests had 91 classes.
|
Concerning failing MPS tests: Let's skip the tests on MPS |
|
The link |
|
@vfdev-5 , any blocker on this? |
|
@sadra-barikbin can you please fix meanwhile the issue with |
|
Any blocker on this? If something is missing I can volunteer to finish / fix it. I am using this and would love to see it merged ❤️ |
vfdev-5
left a comment
There was a problem hiding this comment.
Let's move forward with this PR
LGTM!
Thanks a lot @sadra-barikbin for this great addition !
@tarbaig Thanks for the feedback. I think we can merge this PR. It remains to fix the problems with |
|
@sadra-barikbin can you please fix this issue with older pytorch versions (v1.10-v1.13.1): |

Description:
Mean Average Precision metric for detection in COCO dataset.
Check list: