arduino / arduino/ArduinoTensorFlowLiteTutorials
TFLite MicroInterpreter() never returns on Arduino Nano BLE 33 Sense
- Ngôn ngữ chính
- Jupyter Notebook
- Star
- 270
- Fork
- 122
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
I am trying out the gesture recognization example using the **IMU_Classifier** example for detecting a "punch" gesture.
I see that the Arduino setup() code is kind of blocked when trying to initialize a MicroInterpreter() instance as below.
```
// Create a static memory buffer for TFLM, the size may need to
// be adjusted based on the model you are using
constexpr int tensorArenaSize = 8 * 1024;
byte tensorArena[tensorArenaSize];
tfLiteInterpreter = new tflite::MicroInterpreter(tfLiteModel,tfLiteOpsResolver, tensorArena, tensorArenaSize, &tfLiteErrorReporter);
```
Could you please share if this could be due to model size or any other dependency not being met? I gave it a try by shrinking model layers to reduce the model size as below but I still see an issue. Here, I am only trying to classify the punch gesture.
```
`# build the model and train it
model = tf.keras.Sequential()
model.add(tf.keras.layers.Dense(16, activation='relu'))
model.add(tf.keras.layers.Dense(8, activation='relu'))
model.add(tf.keras.layers.Dense(NUM_GESTURES, activation='sigmoid')) # softmax is used, because we only expect one gesture to occur per input
model.compile(optimizer='rmsprop', loss='mse', metrics=['mae'])
history = model.fit(inputs_train, outputs_train, epochs=600, batch_size=1, validation_data=(inputs_validate, outputs_validate))
`
```
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Hướng nghiên cứu
Bắt đầu từ setup() của ví dụ IMU_Classifier và phần khởi tạo tflite::MicroInterpreter được minh họa trên Arduino Nano BLE 33 Sense. Kiểm tra model, tensor arena 8 KB và các dependency được nêu để xác định tại sao quá trình khởi tạo không bao giờ trả về. Hoàn thành khi đã xác định được nguyên nhân và ví dụ punch-classification có thể hoàn tất setup mà không bị block.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- arduino, jupyter-notebook, keras, tensorflow
- Lĩnh vực
- embedded-iot, machine-learning
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 25/100