Open davidwhealey opened 7 years ago
It is fixed on main repository: https://github.com/fchollet/keras/blob/master/keras/applications/imagenet_utils.py
And yes, you were right!
@fchollet can you confirm whether released models were trained with such erroneous preprocessing function? If so, releasing new pre-trained models for all nets will help a lot.
In ksimonyan/VGG_ILSVRC_16_layers_deploy.prototxt, it states:
preprocess_input() implements like so:
Since the values are subtracted before the channels are swapped, the (R) mean is subtracted from the (B) channel and vice versa.
Of course, it may be that this version is correct and ksimonyan/VGG_ILSVRC_16_layers_deploy.prototxt has the order backwards