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

draw.py doesn't work #5445

Closed
almln opened this issue Mar 24, 2017 · 2 comments
Closed

draw.py doesn't work #5445

almln opened this issue Mar 24, 2017 · 2 comments

Comments

@almln
Copy link

almln commented Mar 24, 2017

Issue summary

When use draw_net_to_file() from pyCaffe get error like "no field _values". After debugging i found that there are "if" statements around line 107 in draw.py like

if len(layer.pooling_param.some_param._values) else 0

But this fields are not lists (for pooling layer), and here is error arise.

Small fix make it works fine: just remove "if" and pass params values directly. I can't find where is draw funtions were broken, but it may be connected with protobuf generation and "repeated" values in caffe.proto.

Caffe: master at 793bd96

Steps to reproduce

net = caffe_pb.NetParameter()
text_format.Merge(open('LeNet.proto').read(), net2)
caffe.draw.draw_net_to_file(net, 'net.png')

Your system configuration

Operating system: Ubuntu 16.04.2
Compiler: gcc 5.4.0
CUDA version: release 7.5, V7.5.17
CUDNN version: 5.0.5
Python 2.7.12
libprotoc 2.6.1

@almln almln changed the title draw.py not works draw.py doesn't works Mar 24, 2017
@almln almln changed the title draw.py doesn't works draw.py doesn't work Mar 24, 2017
@almln
Copy link
Author

almln commented Mar 24, 2017

connected with #3698

@shelhamer
Copy link
Member

Thanks for reporting the issue! Fixed in #5477 and #5487.

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