构造函数:
Net类有两个构造函数,分别是Net(const NetParameter& param, const Net* root_net)
和Net(const string& param_file, Phase phase, const Net* root_net)
,前者接受NetParameter
的const引用作为参数(后面参数root_net与多GPU并行训练有关,忽略掉并不影响理解),后者接受定义网络prototxt文件路径和phase
作为输入。
其中phase有两个变量,分别为TEST与TRAIN
原文:http://blog.csdn.net/withwsf/article/details/51491862