This is the implementation of Number recognition using Keras-MNIST model on Apple's CoreML Framework.
The app fetches image from your hand writing and perform number recognition in real-time.
- Xcode 10.0 beta
- iOS 12
- For training: Python 3.6 (Keras 2.1.6, TensorFlow 1.5.0, CoreMLTools 2.0b1)
To use this app, open iOS-CoreML-MNIST.xcodeproj in Xcode 10 and run it on a device with iOS 12. (You can also use simulator)
If you want to train your own custom model, follow the tutorial given below to create an anaconda environment. Enter the environment and run the following commands in terminal with
./nnet as master directory.
(coreml) $ python train.py (coreml) $ python convert.py
I also included a jupyter notebook for better understanding the above code. You need to use it with root permissions for mainly converting the keras model to CoreML model. Initialise the jupyter notebook instance with the following command:
(coreml) $ jupyter notebook --allow-root
If you are interested in training your custom MNIST model from scratch, a step-by-step tutorial is available at - Link
These are the results of the app when tested on iPhone 7.
Sri Raghu Malireddi / @r4ghu