neil-tan / uTensor
- воскресенье, 5 ноября 2017 г. в 03:13:39
AI inference library based on mbed and TensorFlow
uTensor is an extreme light-weight Deep-Learning Inference framework built on mbed and Tensorflow.
This project is under going constant development. The development is running on develop branch.
mbed detect to see which target is connect to the board
mbedls -l to list all supported targets
See mbed_app.json
mbed deploy to download all referenced librariesmbed compile -t GCC_ARM -m NUCLEO_F767ZI --profile=./build_profile/release.json to build for ST NUCLEO F767ZI. Or, mbed compile -t GCC_ARM -m NUCLEO_F767ZI --profile=./build_profile/release.json -f to compile and flashThe test data has to be loaded to the SD card for the default binary to run:
pip install -r requirements.txt (Note: may have to use pip3)[project]\TESTS\scripts folderpython3 compileTestData.py. This will create [project]\TESTS\scripts\testData directory.[project]\TESTS\scripts\testData to the root of your SD card.The quantized weight and input data are stored in the SD. Setting the serial baud rate to 115200, here is what you should see:
Deep MLP on Mbed (Trained with Tensorflow)
running deep-mlp...
PASSED 0.00000000
prediction: 7
Currently, the binary runs the first sample of the MNIST dataset which contains a handwritten digit of number 7. Ths network architecture is a 3-layer Relu based MLP, as shown below:
The related Tensorflow training script please refer to the node-viewer project.