nilboy / extract-caffe-params Goto Github PK
View Code? Open in Web Editor NEWextract caffe model's parameters to numpy array, and write them to files
extract caffe model's parameters to numpy array, and write them to files
thanks your extract.py for caffe !!
It saves me a lot of time.
Hi Xia,
I am using your python parser for caffemodel. However, I run into following issue:
I0208 23:29:19.620373 42087 net.cpp:437] conv4 needs backward computation.
I0208 23:29:19.620442 42087 net.cpp:437] relu3 needs backward computation.
I0208 23:29:19.620515 42087 net.cpp:437] conv3 needs backward computation.
I0208 23:29:19.620591 42087 net.cpp:437] pool2 needs backward computation.
I0208 23:29:19.620656 42087 net.cpp:437] norm2 needs backward computation.
I0208 23:29:19.620725 42087 net.cpp:437] relu2 needs backward computation.
I0208 23:29:19.620793 42087 net.cpp:437] conv2 needs backward computation.
I0208 23:29:19.620863 42087 net.cpp:437] pool1 needs backward computation.
I0208 23:29:19.620964 42087 net.cpp:437] norm1 needs backward computation.
I0208 23:29:19.621076 42087 net.cpp:437] relu1 needs backward computation.
I0208 23:29:19.621137 42087 net.cpp:437] conv1 needs backward computation.
I0208 23:29:19.621201 42087 net.cpp:439] label_data_1_split does not need backward computation.
I0208 23:29:19.621268 42087 net.cpp:439] data does not need backward computation.
I0208 23:29:19.621330 42087 net.cpp:481] This network produces output accuracy
I0208 23:29:19.621392 42087 net.cpp:481] This network produces output loss
I0208 23:29:19.621491 42087 net.cpp:521] Network initialization done.
convert layer: conv1
Traceback (most recent call last):
File "extract.py", line 36, in
extract_caffe_model(args.model, args.weights, args.output)
File "extract.py", line 27, in extract_caffe_model
np.save(output_path + '/' + str(name) + '_' + str(num), p.data)
File "/usr/lib64/python2.7/site-packages/numpy/lib/npyio.py", line 511, in save
pickle_kwargs=pickle_kwargs)
File "/usr/lib64/python2.7/site-packages/numpy/lib/format.py", line 562, in write_array
version)
File "/usr/lib64/python2.7/site-packages/numpy/lib/format.py", line 308, in _write_array_header
header = asbytes(_filter_header(header))
File "/usr/lib64/python2.7/site-packages/numpy/lib/format.py", line 467, in _filter_header
return tokenize.untokenize(tokens)
File "/usr/lib64/python2.7/tokenize.py", line 262, in untokenize
return ut.untokenize(iterable)
File "/usr/lib64/python2.7/tokenize.py", line 198, in untokenize
self.add_whitespace(start)
File "/usr/lib64/python2.7/tokenize.py", line 187, in add_whitespace
assert row <= self.prev_row
Network is AlexNet. Would you be able to help me why this may be occuring?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.