saved_model.zip
), ONNX model (.onnx
) or LiteRT (previously Tensorflow Lite) model (.tflite
)
For this guide, we will be uploading a pretrained image classification TFLite model for plant disease classification.
Then, from the Dashboard, of your Edge Impulse project under “Getting started”, select Upload your model:
Edge Impulse project dashboard, showing the project overview and getting started options.
saved_model.zip
), ONNX model (.onnx
) or LiteRT (previously Tensorflow Lite) model (.tflite
) to get started..npy
file to Upload representative features (Optional) - for example, your validation set - as an .npy
file. This way, we can automatically quantize this model for better on-device performance. See quantization below.Uploading a pretrained .onnx model
int8
numeric representation rather than float32
, which can result in reduced memory usage and faster computation on many targets.Quantization is currently only supported for SavedModel or ONNX uploadsQuantization requires a sample of data that is representative of the range (maximum and minimum) of values in your training data. In the Studio, we require a numpy file (.npy
). Each element of the array must have the same shape as your model’s input.Note that quantization is a form of lossy compression and may result in a reduction in model performance. It’s important to evaluate your model after quantization to ensure it still performs well enough for your use case.(300, 300, 3)
in RGB format, Classification model output and 16 output labels: Tomato Healthy, Tomato Septoria Leaf Spot, Tomato Bacterial Spot, Tomato Blight, Cabbage Healthy, Tomato Spider Mite, Tomato Leaf Mold, Tomato_Yellow Leaf Curl Virus, Soy_Frogeye_Leaf_Spot, Soy_Downy_Mildew, Maize_Ravi_Corn_Rust, Maize_Healthy, Maize_Grey_Leaf_Spot, Maize_Lethal_Necrosis, Soy_Healthy, Cabbage Black Rot
After configuring your model settings, select Save model to view your model’s on-device performance information for both MCUs and microprocessors (if applicable, depending on your model’s arena size).
Step 2: Process your model
Step 2: Check model behavior
Step 2: Check model behavior results
(1,320,320,3)
), and the batch size must be equal to 1. For ONNX models you can use a variable batch size (we’ll set it to 1).(1,3)
.(1,1)
..zip
archive containing at minimum a saved_model
directory that contains your saved_model.pb
.
Could not profile: No uploaded model yet
If you encounter the following error:
Clear model and revert to impulse mode on the project Dashboard
extract_XXXX_features
to preprocess your sensor data, and pass the resulting features into the ei_run_classifier
function.