There is a data blob of hdf5 [600000,1,7,256].The function 'compute_image_mean.cpp' in Caffe is not fit for HDF5. So how to do mean subtraction using Caffe in matlab?
Suppose you have a matrix in MATLAB of 60K vectors, how would you subtract the mean in MATLAB?
X=bsxfun(@minus, X, mean(X, 1));
Now that you subtracted the mean you can save X to hdf5 and feed it to caffe.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With