sksq96 / pytorch-summary

Model summary in PyTorch similar to `model.summary()` in Keras
MIT License
3.98k stars 412 forks source link

Crash on yolact summary #76

Open apletea opened 5 years ago

apletea commented 5 years ago

Hi!

I am using this repo for geting model of yolact https://github.com/dbolya/yolact.

When I am trying to get summary it fallows as "AttributeError: 'list' object has no attribute 'size'".

And after applying summary this model didnt work at all. But before it inference works.

So can you help me to find the any problems here?

ZvukZTyshyny commented 5 years ago

should fix: summary[m_key]["input_shape"] = list(input[0].size()) summary[m_key]["input_shape"][0] = batch_size to

summary[m_key]["input_shape"] = list(input[0].size())

 #summary[m_key]["input_shape"][0] = batch_size
sicarioakki commented 4 years ago

@sksq96 @ZvukZTyshyny @apletea I am too facing the same issue while trying to get the summary of Yolact model. Any idea as to how to solve this??

TylerYep commented 4 years ago

Should be fixed in my Fork - see #124