Hi, thanks for releasing the code for INP-Former — great paper and clean implementation!
I noticed a discrepancy between the paper and this repo that might be worth
clarifying, in case other reimplementations run into the same confusion.
Paper: Eq. (1) in Sec. 3.2 defines the multi-layer feature fusion as an
explicit element-wise sum:
F_Q = sum({f^1_Q, ..., f^L_Q}), where sum(·) denotes the element-wise summation.
Appendix A ("More implementation details") also describes the group-to-group
supervision strategy as "summing the features of the layers of interest to
form distinct groups."
Code: INP_Former.fuse_feature
computes the mean instead:
def fuse_feature(self, feat_list):
return torch.stack(feat_list, dim=1).mean(dim=1)
Question: is mean the actually-intended op (and Eq. 1 / Appendix A
should say mean instead of sum), or should this be sum and the code is a
leftover from an earlier version?
Hi, thanks for releasing the code for INP-Former — great paper and clean implementation!
I noticed a discrepancy between the paper and this repo that might be worth
clarifying, in case other reimplementations run into the same confusion.
Paper: Eq. (1) in Sec. 3.2 defines the multi-layer feature fusion as an
explicit element-wise sum:
Appendix A ("More implementation details") also describes the group-to-group
supervision strategy as "summing the features of the layers of interest to
form distinct groups."
Code:
INP_Former.fuse_featurecomputes the mean instead:
Question: is mean the actually-intended op (and Eq. 1 / Appendix A
should say mean instead of sum), or should this be sum and the code is a
leftover from an earlier version?