Skip to content
New issue

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

FSAF on mmdet v2.0 #2520

Closed
wants to merge 12 commits into from
Prev Previous commit
Next Next commit
fixed the nan bbox_loss by clamping bbox_pred with min=1e-4
  • Loading branch information
Johnson-Wang committed Apr 23, 2020
commit fece78dd2cd4e8eb0d99a9b2714c00a12f1959b5
4 changes: 2 additions & 2 deletions mmdet/models/anchor_heads/fsaf_head.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@ def loss(self,
all_anchor_list = images_to_levels(concat_anchor_list,
num_level_anchors)
for i in range(len(bbox_preds)):
bbox_preds[i].clamp_(
min=1e-4) # avoid 0 area of the predicted bbox
bbox_preds[i] = bbox_preds[i].clamp(min=1e-4)
# avoid 0 area of the predicted bbox
losses_cls, losses_bbox = multi_apply(
self.loss_single,
cls_scores,
Expand Down