batuman
batuman

Reputation: 7314

Understanding caffe library

I use caffe library for Deep Learning.

I am a bit confuse about how the library works.

What I understood is

APIs in net.cpp, net.h are interfaces to user's applications.

net.cpp, net.h use APIs from caffe.pb.cc, caffe.pb.h.

What I confuse are

(1)What is the relationships between layers in caffe/src/caffe/layers and caffe.pb.cc, caffe.pb.h?

(2)What does this class NetParameter inside caffe.pb.h do and what is its purpose?

(3)What is this caffe.pb for?

Upvotes: 0

Views: 65

Answers (1)

Shai
Shai

Reputation: 114976

Caffe uses google protocol buffer ("pb") to define the network structure. When creating/downloading caffe model you'll see a 'train.prototxt' or 'deploy.prototxt' files. These files are written according to caffe's protocol buffer syntax (defined in caffe.proto).
This protocol buffer is then compiled into c++ interface that is defined in the automatically generated caffe.pb.cc and caffe.pb.h files.

NetParameter structure is the datatype defined in caffe.proto and responsible for representing a "net". The functional implementation of the various layers can be found in src/caffe/layers/*.cpp files.

Upvotes: 1

Related Questions