Swin-Transformer icon indicating copy to clipboard operation
Swin-Transformer copied to clipboard

Which tool/method you used to count flops?

Open yushuinanrong opened this issue 3 years ago • 5 comments

yushuinanrong avatar Jul 17 '21 21:07 yushuinanrong

just google yourself

tb2-sy avatar Oct 24 '21 03:10 tb2-sy

@tb2-sy What does matter in my research (probably the same for many other researchers) is to make sure that I can reproduce the reported numbers. I'm aware of many flop counting tools and they often produce different results. That's why I bring this up in the issue. Hope you can understand my point and learn to mind your attitude next time when you post anything online.

yushuinanrong avatar Oct 24 '21 03:10 yushuinanrong

The code can be found here: https://github.com/microsoft/Swin-Transformer/blob/b05e6214a37d33846903585c9e83b694ef411587/models/swin_transformer.py#L578-L585

zeliu98 avatar Dec 20 '21 16:12 zeliu98

The code can be found here:

https://github.com/microsoft/Swin-Transformer/blob/b05e6214a37d33846903585c9e83b694ef411587/models/swin_transformer.py#L578-L585

Hello, I have a question about FLOPs. On the ADE20K, the FLOPs of Swin-B are 1841G, but the backbone of Swin-B is only tens of G. Is it because of the large amount of calculation of the decoder?

bobopit avatar Jan 11 '22 12:01 bobopit

The code can be found here:

https://github.com/microsoft/Swin-Transformer/blob/b05e6214a37d33846903585c9e83b694ef411587/models/swin_transformer.py#L578-L585

It seems this code snippet is for #Parameters calculation, not for FLOPs. Can you give more explanations? Thanks

auniquesun avatar Aug 14 '22 02:08 auniquesun