updated caffe module and modified related stuff