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

[PyTocrhv1:第四、五章问题收集] #76

Open
ZhikangNiu opened this issue Dec 7, 2023 · 5 comments
Open

[PyTocrhv1:第四、五章问题收集] #76

ZhikangNiu opened this issue Dec 7, 2023 · 5 comments

Comments

@ZhikangNiu
Copy link
Collaborator

No description provided.

@AlbertLuk
Copy link

你好,5.3.3 的修改模型输出是不是没有输出中间层,self.net(x)输出的应该是已经是经过fc层了。
我打印了模型的网络结构发现和你表述的好像不一样诶
image
image

@ZhikangNiu
Copy link
Collaborator Author

model.net 输出
image

model 输出
image

不建议通过这种方式去看模型的forward过程

@AlbertLuk
Copy link

感谢回复!
明白,看来是我理解错了文中的意思,我以为中间结果指的avgpool后的结果。
如果要得到avgpool后的输出应该是要用hook或者修改原始resnet50的forward函数对吧?

@ZhikangNiu
Copy link
Collaborator Author

感谢回复! 明白,看来是我理解错了文中的意思,我以为中间结果指的avgpool后的结果。 如果要得到avgpool后的输出应该是要用hook或者修改原始resnet50的forward函数对吧?

是,但是修改后的有两个返回值的,一个就是resnet50的结果

@ZHeeeL
Copy link

ZHeeeL commented May 29, 2024

这行代码运行要很久,一直都不能显示图片,请问是什么原因
1

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

3 participants