mengyuest / AdaFuse

AdaFuse: Adaptive Temporal Fusion Network for Efficient Action Recognition (ICLR 2021)
33 stars 4 forks source link

Gumbel Softmax #2

Open rayush7 opened 2 years ago

rayush7 commented 2 years ago

Hi, Could you please point out where the gumbel softmax is applied in the code? I am unable to find it.

Thanks

wanghao14 commented 2 years ago

@rayush7 You can find the gumbel softmax here: https://github.com/mengyuest/AdaFuse/blob/91c3a5d5ba524bb8cd847fd8a076a220fae0050f/ops/batenet.py#L217

rayush7 commented 2 years ago

Thank you @wanghao14 .

Could you also help me find the part where Equation (2) and Equation (3) in the AdaFuse paper has been implemented?

Thanks

mengyuest commented 7 months ago

Thank you @wanghao14 .

Could you also help me find the part where Equation (2) and Equation (3) in the AdaFuse paper has been implemented?

Thanks

Sorry for the late reply, as I have worked on other research topics. Regarding your question, both equations are implemented in ./ops/batenet.py (link). To be more specific, the Equation (2) is implemented by the self.gate_fc* layers in the PolicyBlock class (link) and the Equation (3) is implemented in fuse_out_with_mask (link)