Home

Awesome

caffegraph

Load Caffe networks in Torch7 using nngraph.

After installing Torch, ensure that you have the protobuf libraries. On Ubuntu, this might look like

sudo apt-get install libprotobuf-dev protobuf-compiler

or, on Macintosh OperatingSystem 10:

brew install protobuf

You can then install this package using

luarocks install caffegraph

Then, similarly to loadcaffe,

caffegraph = require 'caffegraph'
model = caffegraph.load('deploy_resnet152.prototxt', 'resnet152.caffemodel')

Note that some modules that are loadable using loadcaffe are not yet implemented in caffegraph. You are welcome to submit a PR with any that you feel are missing!

caffe.proto is used under license from the University of California.