Visual-Attention-Network / SegNeXt

Official Pytorch implementations for "SegNeXt: Rethinking Convolutional Attention Design for Semantic Segmentation" (NeurIPS 2022)
Apache License 2.0
796 stars 85 forks source link

Are params really exact? #17

Closed Monkey0806 closed 2 years ago

Monkey0806 commented 2 years ago
  The params which you exhibit in the tables are 4M, 14M, 28M, 49M (T, S, B, L).But the size of pertained models in the "TsingHua Cloud"  are about 50, 168, 322, 543 MB(T, S, B, L).
  I think the size of pretrained model should equal to (params  x  4B), because one parameter saved as a float32 number which occupy 4 Bytes in memory. So the parameters inferred from pertained models should be **12M, 44M, 80M, 134M.**
 Maybe I misunderstand the rules of memory calculation by params. **Or could you explain?**
uyzhang commented 2 years ago

The pertained models in the "TsingHua Cloud" have other information. You can get params using some tools like torchprofile, and can read the code to get details of calculation

截屏2022-10-16 15 30 10
Monkey0806 commented 2 years ago

Thanks for your reply.I just checked the size of 'state_dict', which size actually matches the params.