BasicSR icon indicating copy to clipboard operation
BasicSR copied to clipboard

model parameters

Open Yzs007 opened this issue 2 years ago • 4 comments

How to calculate model parameters in BasicSR? When I use thop.profile, the following error occurs:

D:\anaconda3\envs\Pytorch\python.exe C:/Users/DELL/Desktop/BSRN-main/para.py Traceback (most recent call last): File "C:\Users\DELL\Desktop\BSRN-main\para.py", line 9, in flops, params = profile(model, inputs=(input,), verbose=True) File "D:\anaconda3\envs\Pytorch\lib\site-packages\thop\profile.py", line 206, in profile prev_training_status = model.training AttributeError: 'dict' object has no attribute 'training'

Process finished with exit code 1

Yzs007 avatar Dec 26 '22 07:12 Yzs007

Have you solved this problem yet? I am currently experiencing the similar problem.If convenience,could you help me?

Rheazheng avatar Mar 08 '23 02:03 Rheazheng

Have you solved this problem yet? I am currently experiencing the similar problem.If convenience,could you help me?

from torchsummaryX import summary if name=='main': scale = 4 input = torch.zeros(1, 3, 1280//scale, 720//scale) model = Net(in_chan=3, out_chan=3, dim=64, upscale=scale) summary(model, input)

Yzs007 avatar Mar 08 '23 05:03 Yzs007

Have you solved this problem yet? I am currently experiencing the similar problem.If convenience,could you help me?

Miscorf avatar Mar 09 '23 10:03 Miscorf

Have you solved this problem yet? I am currently experiencing the similar problem.If convenience,could you help me?

What's your problem?

Yzs007 avatar Mar 09 '23 10:03 Yzs007