LArbys / LArCV

Liquid Argon Computer Vision
11 stars 9 forks source link

use_thread check #54

Closed vgenty closed 7 years ago

vgenty commented 7 years ago

Should we have a check between use_thread: in caffe's prototxt and UseThread: in the ProcessDriver configuration? I can set use_thread: false in my root_data_layer configuration, but my filler will still use threading as we not making a check. Users may forget to set both.

drinkingkazu commented 7 years ago

Yeah this is terrible. We must fix it. I guess a natural place is to take out from prototxt. I'll take a look.

drinkingkazu commented 7 years ago

I changed apcaffe_cleanup branch of caffe repository (our fork). One needs to pull & re-build caffe.

drinkingkazu commented 7 years ago

@vgenty I believe this is confirmed to be fixed. If you agree would you close it?

vgenty commented 7 years ago

I await your push to https://github.com/LArbys/caffe which resolves out of scope filler in src/caffe/layers/root_data_layer.cpp

src/caffe/layers/root_data_layer.cpp: In member function 'virtual void caffe::ROOTDataLayer<Dtype>::LoadROOTFileData()':
src/caffe/layers/root_data_layer.cpp:36:14: error: 'filler' was not declared in this scope
     }else if(filler.thread_config()){
              ^
src/caffe/layers/root_data_layer.cpp:37:13: error: redeclaration of 'auto& filler'
       auto& filler = ::larcv::ThreadFillerFactory::get_filler(name);
             ^
src/caffe/layers/root_data_layer.cpp:36:14: error: '<typeprefixerror>filler' previously declared here
     }else if(filler.thread_config()){
              ^
src/caffe/layers/root_data_layer.cpp:56:8: error: 'filler' was not declared in this scope
     if(filler.thread_config()) {
        ^
src/caffe/layers/root_data_layer.cpp:57:13: error: redeclaration of 'auto& filler'
       auto& filler = ::larcv::ThreadFillerFactory::get_filler(name);
             ^
src/caffe/layers/root_data_layer.cpp:56:8: error: '<typeprefixerror>filler' previously declared here
     if(filler.thread_config()) {
        ^
make: *** [.build_debug/src/caffe/layers/root_data_layer.o] Error 1
make: *** Waiting for unfinished jobs....

make: *** wait: No child processes.  Stop.
drinkingkazu commented 7 years ago

yep sorry just forgot about it. Here: https://github.com/LArbys/caffe/commit/05503866dcec04388ab7e8ebf1658745c21baea6

vgenty commented 7 years ago

thanks, i confirmed it builds OK