| 31 | } |
| 32 | |
| 33 | virtual void InitNetFromProtoFileWithState(const string& proto, |
| 34 | Phase phase = caffe::TRAIN, const int level = 0, |
| 35 | const vector<string>* stages = NULL) { |
| 36 | NetParameter param; |
| 37 | CHECK(google::protobuf::TextFormat::ParseFromString(proto, ¶m)); |
| 38 | string param_file; |
| 39 | MakeTempFilename(¶m_file); |
| 40 | WriteProtoToTextFile(param, param_file); |
| 41 | net_.reset(new Net<Dtype>(param_file, phase, level, stages)); |
| 42 | } |
| 43 | |
| 44 | virtual void CopyNetBlobs(const bool copy_diff, |
| 45 | vector<shared_ptr<Blob<Dtype> > >* blobs_copy) { |
nothing calls this directly
no test coverage detected