Android: Use the Classifier interface in the activities.
Change the member variable to be of type Classifier interface instead of the implementation (TensorFlowImageClassifier) in the activity class. My intention is to create new Classifier implementations that use the TensorFlow Java API (org.tensorflow.Graph, Session etc.) instead of the Android contrib API (org.tensorflow.contrib.android.TensorFlowInferenceInterface). This re-organization will make the switch between Classifier implementations easier during testing. While at it, some minor cleanups: - Get rid of unnecessary "throws IOException" - Use a factory function instead of an initializer function. Change: 144348772
Showing
想要评论请 注册 或 登录