keras-team / keras-applications

Reference implementations of popular deep learning models.
Other
2k stars 910 forks source link

preprocessing not syncronised this weights for MobileNetv2 #65

Closed MichaelMonashev closed 5 years ago

MichaelMonashev commented 5 years ago

After this commit https://github.com/keras-team/keras-applications/commit/5f99f5238d83f1d9b9822ad750d2d8f1e017af92 I think pretrained weights have to be changed too.

MichaelMonashev commented 5 years ago

This is not equal! before:

    x /= 128.
    x -= 1.

now:

        x /= 127.5
        x -= 1.
taehoonlee commented 5 years ago

Thank you for the report, @MichaelMonashev. We must synchronize with tensorflow-models which is an origin of the pre-trained weights in MobileNetv2. Thus, the number that is used in tensorflow-models, 127.5, is correct.