Skip to content

Commit

Permalink
fix the use of cfg in workers
Browse files Browse the repository at this point in the history
  • Loading branch information
ppwwyyxx committed Oct 19, 2019
1 parent a6ca79c commit 74badc6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/FasterRCNN/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ def __call__(self, roidb):
points = tfms.apply_coords(points)
boxes = point8_to_box(points)
if len(boxes):
assert klass.max() <= cfg.DATA.NUM_CATEGORY, "Invalid category {}!".format(klass.max())
assert klass.max() <= self.cfg.DATA.NUM_CATEGORY, \
"Invalid category {}!".format(klass.max())
assert np.min(np_area(boxes)) > 0, "Some boxes have zero area!"

ret = {"image": im}
Expand Down

0 comments on commit 74badc6

Please sign in to comment.