We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Error at line https://github.com/NVIDIA/retinanet-examples/blob/main/odtk/box.py#L299
291 classes = (indices / width / height) % num_classes 292 classes = classes.type(all_cls_head.type()) 293 294 # Infer kept bboxes 295 x = indices % width 296 y = (indices / width) % height 297 a = indices / num_classes / height / width 298 box_head = box_head.view(num_anchors, num_boxes, height, width) 299 boxes = box_head[a, :, y, x] ---------------------------------------------------------> IndexError
use '//' instead of '/' to fix the issue, fixed code below;
291 classes = (indices // width // height) % num_classes 292 classes = classes.type(all_cls_head.type()) 293 294 # Infer kept bboxes 295 x = indices % width 296 y = (indices // width) % height 297 a = indices // num_classes // height // width 298 box_head = box_head.view(num_anchors, num_boxes, height, width) 299 boxes = box_head[a, :, y, x]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Error at line https://github.com/NVIDIA/retinanet-examples/blob/main/odtk/box.py#L299
291 classes = (indices / width / height) % num_classes
292 classes = classes.type(all_cls_head.type())
293
294 # Infer kept bboxes
295 x = indices % width
296 y = (indices / width) % height
297 a = indices / num_classes / height / width
298 box_head = box_head.view(num_anchors, num_boxes, height, width)
299 boxes = box_head[a, :, y, x] ---------------------------------------------------------> IndexError
use '//' instead of '/' to fix the issue, fixed code below;
291 classes = (indices // width // height) % num_classes
292 classes = classes.type(all_cls_head.type())
293
294 # Infer kept bboxes
295 x = indices % width
296 y = (indices // width) % height
297 a = indices // num_classes // height // width
298 box_head = box_head.view(num_anchors, num_boxes, height, width)
299 boxes = box_head[a, :, y, x]
The text was updated successfully, but these errors were encountered: