-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
add SQR for Deformable DETR #8579
Conversation
Thanks for your contribution! |
@@ -122,9 +122,10 @@ def forward(self, | |||
out_bbox.unsqueeze(1) - tgt_bbox.unsqueeze(0)).abs().sum(-1) | |||
|
|||
# Compute the giou cost betwen boxes | |||
cost_giou = self.giou_loss( | |||
giou_loss = self.giou_loss( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这块改的原因是什么 对其他模型通用嘛
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这块原本的cost_giou是算错的,不过对后面计算linear_sum_assignment没有影响,所以其他模型也没有影响
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
建议你新增一个flag 其他的模型就不需要重新验证了
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
建议你新增一个flag 其他的模型就不需要重新验证了
我觉得不需要,cost_giou只被用在计算C,C只被用在计算linear_sum_assignment,而cost_giou整体增大一个常数对linear_sum_assignment是没有影响的
ppdet/metrics/metrics.py
Outdated
@@ -124,7 +124,7 @@ def update(self, inputs, outputs): | |||
|
|||
def accumulate(self): | |||
if len(self.results['bbox']) > 0: | |||
output = "bbox.json" | |||
output = f"bbox_{paddle.distributed.get_rank()}.json" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这块改的原因是什么
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
为了避免多卡eval时,重复写入造成文件损坏。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
现在的ppdet多卡eval逻辑是不对的 没有mege最终的结果的逻辑 这块还保持原来的逻辑吧
另外在configs下面加一个简单的readme吧 |
加了 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
基于PPDET Deformable DETR复现SQR增强策略 #8498
测试环境:
启动脚本如下: