You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wondered, what is the use of mean_file param under data_param. If it is deprecated, I didn't found any comments in the proto file indicating that. Apparently, it didn't work like its literal meaning.
Steps to reproduce
I was using googlenet to do classifications. I got high validation accuracy during training. Unfortunately, I got weird low test accuracy during testing. I tried to many things like adjusting train sets, modifying learning rate, gamma and so on, I got totally different results even if the modifications were very subtle.
At last, I found that I used the 'mean_file' param under 'data_param' in data layer instead of in 'transform_param'. And it was the cause of weird output of testing. In fact, during initialization of network, it didn't load the mean_file param if it was under the data_param.
And I looked into the caffe.proto file and indeed there is a mean_file param in data_param. That's why no error raised. But still it seems that it is of no use.
Your system configuration
Operating system:
Compiler:
CUDA version (if applicable):
CUDNN version (if applicable):
BLAS:
Python or MATLAB version (for pycaffe and matcaffe respectively):
The text was updated successfully, but these errors were encountered:
Noiredd
changed the title
What is the use of param 'mean_file' under data_param
DataParameter field 'mean_file' should be deprecated?
Jan 12, 2018
Interesting. Initially mean_file and similar parameters were fields of a DataParameter message and the DataLayer handled all preprocessing. Then (#954) the code was refactored into the Transformer class with its own TransformerParameter message that took over mean_file and other preprocessing fields. Later (#963) the fields were brought back for compatibility reasons, and finally (#995) the preprocessing was entirely moved to the Transformer. Legacy proto definitions are upgraded using the upgrade_proto.cpp utility which moves any mean_file passed as data_param into the transform_param - but indeed it seems that caffe.proto is not very clear about this fact:
// DEPRECATED. See TransformationParameter. For data pre-processing, we can do
// simple scaling and subtracting the data mean, if provided. Note that the
// mean subtraction is always carried out before scaling.
optional float scale = 2 [default = 1];
optional string mean_file = 3;
Issue summary
I wondered, what is the use of mean_file param under data_param. If it is deprecated, I didn't found any comments in the proto file indicating that. Apparently, it didn't work like its literal meaning.
Steps to reproduce
I was using googlenet to do classifications. I got high validation accuracy during training. Unfortunately, I got weird low test accuracy during testing. I tried to many things like adjusting train sets, modifying learning rate, gamma and so on, I got totally different results even if the modifications were very subtle.
At last, I found that I used the 'mean_file' param under 'data_param' in data layer instead of in 'transform_param'. And it was the cause of weird output of testing. In fact, during initialization of network, it didn't load the mean_file param if it was under the data_param.
And I looked into the caffe.proto file and indeed there is a mean_file param in data_param. That's why no error raised. But still it seems that it is of no use.
Your system configuration
Operating system:
Compiler:
CUDA version (if applicable):
CUDNN version (if applicable):
BLAS:
Python or MATLAB version (for pycaffe and matcaffe respectively):
The text was updated successfully, but these errors were encountered: