Skip to content
This repository was archived by the owner on Dec 1, 2021. It is now read-only.

Commit

Permalink
Avoid ValueError for TFDS with BBox on the last pixel (#1209)
Browse files Browse the repository at this point in the history
## What this patch does to fix the issue.
Fix #1208 

## Link to any relevant issues or pull requests.
  • Loading branch information
hadusam authored Sep 24, 2020
1 parent f65fac0 commit ee53474
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions blueoil/utils/tfds_builders/object_detection.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ def _generate_examples(self, dataset):
"bbox": tfds.features.BBox(
ymin / height,
xmin / width,
(ymin + h) / height,
(xmin + w) / width,
min((ymin + h) / height, 1.0),
min((xmin + w) / width, 1.0),
)
}
for xmin, ymin, w, h, label in annotations
Expand Down

0 comments on commit ee53474

Please sign in to comment.