keras-team / keras-applications

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

remove global image mean from utils. #121

Closed tanzhenyu closed 5 years ago

taehoonlee commented 5 years ago

@tanzhenyu, This PR is redundant to #86, and the issue has not been fully discussed yet. @fchollet, Does he have permission to merge to the master branch?

tanzhenyu commented 5 years ago

@taehoonlee We have discussed and reached a consensus not to create global states. The issue referenced above is a legitimate issue, and it happens somewhere else as well.

I see you have concerns for memory consumption, but this shouldn't matter for numpy arrays, or for small amount of input tensors which is the regular case. For large amount of input tensors we should consider passing the mean tensor into the function.