Lyken17 / pytorch-OpCounter

Count the MACs / FLOPs of your PyTorch model.
MIT License
4.9k stars 528 forks source link

nn.Transformer #137

Closed HaoKang-Timmy closed 3 years ago

HaoKang-Timmy commented 3 years ago

Push a hook function to count macs for Transformer