Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

some trouble in train 1H #43

Open
CMYCMY1 opened this issue May 19, 2022 · 4 comments
Open

some trouble in train 1H #43

CMYCMY1 opened this issue May 19, 2022 · 4 comments

Comments

@CMYCMY1
Copy link

CMYCMY1 commented May 19, 2022

I've commented <self.layer4 = hourglass_block(128, 128)>、<self.layer3= hourglass_block(128, 128)>、<self.layer2 = hourglass_block(128, 128)> and <result4, out, feature4 = self.layer4(out)>、<result3, out, feature3 = self.layer3(out)>、<result2, out, feature2 = self.layer2(out)> , also I modify the <return [result1, result2, result3, result4], [feature1, feature2, feature3, feature4]> to <return [result1], [feature1]>, and I changed "index=[3]" to "index=[0]",

but there was a problem with the evaluation,The error is displayed as follows “'int' object has no attribute 'data'” .
I would appreciate it if the author could tell me how to solve this problem.

@koyeongmin
Copy link
Owner

I cannot find the reason. I checked some points' ".data" attribute, but there is no int object. If you can share more detailed error messages (line number, ... ), it will be more helpful. Thank you!

@CMYCMY1
Copy link
Author

CMYCMY1 commented May 20, 2022

Thank you for your reply!More error details are shown in the figure:
a3efab9e0016cebb0ac910143aa497e

@koyeongmin
Copy link
Owner

For calculating the attention loss, the deeper network's feature acts as a teacher. However, if you set only one hourglass network to use, there is no teacher network, so "attention_loss" becomes zero, int type (there are no changes from line 253). If you remove the attention loss parts, it will work.

@CMYCMY1
Copy link
Author

CMYCMY1 commented May 23, 2022

It worked.Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants