You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by gi...@git.apache.org on 2017/09/05 18:50:49 UTC
[GitHub] gokererdogan opened a new issue #7745: Bug in DetRandomCropAug
gokererdogan opened a new issue #7745: Bug in DetRandomCropAug
URL: https://github.com/apache/incubator-mxnet/issues/7745
For bugs or installation issues, please provide the following information.
The more information you provide, the more likely people will be able to help you.
## Environment info
Operating System: Ubuntu 16.04
Compiler: gcc 5.4
Package used: Python
MXNet commit hash (`git rev-parse HEAD`): ada6d4e0bbfb6a244a868c8ef6edf40529dd996d
If you are using python package, please provide
Python version and distribution: 3.5.2 (from Ubuntu repo)
## Error Message:
```
File "/mxnet/python/mxnet/image/detection.py", line 750, in next
data, label = self.augmentation_transform(data, label)
File "/mxnet/python/mxnet/image/detection.py", line 772, in augmentation_transform
data, label = aug(data, label)
File "/mxnet/python/mxnet/image/detection.py", line 104, in __call__
return self.aug_list[0](src, label)
File "/mxnet/python/mxnet/image/detection.py", line 188, in __call__
crop = self._random_crop_proposal(label, src.shape[0], src.shape[1])
File "/mxnet/python/mxnet/image/detection.py", line 299, in _random_crop_proposal
if self._check_satisfy_constraints(label, x, y, x + w, y + h, width, height):
File "/mxnet/python/mxnet/image/detection.py", line 229, in _check_satisfy_constraints
coverages = self._calculate_areas(intersects) / object_areas
ValueError: operands could not be broadcast together with shapes (2,) (3,)
```
## Minimum reproducible example
In `DetRandomCropAug._check_satisfy_constraints`, if after cropping, the number of "valid" objects change, the line below throws the above exception.
```
coverages = self._calculate_areas(intersects) / object_areas
```
I believe this line should read
```
coverages = self._calculate_areas(intersects) / object_areas[valid_objects]
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services