open-mmlab / mmcv

OpenMMLab Computer Vision Foundation
https://mmcv.readthedocs.io/en/latest/
Apache License 2.0
5.84k stars 1.63k forks source link

[Feature Request] Better FLOPs Counter #1597

Open kennymckormick opened 2 years ago

kennymckormick commented 2 years ago

Describe the feature

Motivation The current get_model_complexity_info API in MMCV is limited and can only calculate the OPs for specific PyTorch modules, while the Flop Counter in FVCore supports most PyTorch operators. Maybe MMCV can follow the implementation in FVCore to improve the API.

Related resources FVCore API

zhouzaida commented 2 years ago

It is a great suggestion. In fact, we have a plan to support it in the next year.

kennymckormick commented 2 years ago

Nice.