EADST

Check Torch Model Structure, Flops, and Params

Check Torch Model Structure, Flops, and Params

from torchinfo import summary
images.tensors.size() # (3, 640, 640)
summary(torch_model, images.tensors.size())

from thop import profile
flops, params = profile(torch_model, inputs=[images], verbose=False)

from ptflops import get_model_complexity_info
flops, params = get_model_complexity_info(torch_model, (3, 640, 640), as_strings=True, print_per_layer_stat=True)
flops, params = get_model_complexity_info(torch_model, [images.tensors.size()], as_strings=True, print_per_layer_stat=True)
相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
站点统计

本站现有博文242篇,共被浏览290957

本站已经建立1780天!

热门文章
文章归档
回到顶部