Improve Arduino Vision Classification latency on Spresense

I am using the Spresense board and when I use Eon Tuner, I have a predicted latency of about 100ms for Classification. However, when generate an Arduino library and I go to run things, it is clocking in 1064ms. When I build the Spresense firmware, the classification latency is ~500ms.

  1. Is there an easy way to pull the modification from the Firmware into the Arduino library to bring down the classification latency?

  2. Why is the predicted latency in Eon Tuner off by so much? Is there anyway to get down to this latency?

Arduino Library:
Predictions (DSP: 7 ms., Classification: 1064 ms., Anomaly: 0 ms.):

Firmware:
Predictions (DSP: 6 ms., Classification: 530 ms., Anomaly: 0 ms.):

Hello @lukedc,

  1. I don’t know if the Sprense is fully optimized in Arduino IDE (taking advantage of all hardware acceleration like we do when we provide the binaries).
  2. The EON tuner provides an estimation of the latency, so the estimation may vary a bit from the reality but here it should not be that different. Did you use the quantized version of your model for your tests?

Regards,

Louis

Thanks Louis! I double checked and I am using the quantized version. Is there a particular model configuration I should try that would give low latency?

This is the configuration for my current model:

So I loaded the same Arduino model up onto a Arduino Nano Sense 33 BLE. It looks like the Nano is more than twice as slow as the Spresense… yet the latency for Classification is faster. With the Nano it is ~750ms and on the Spresense it is ~1500ms.

Any idea why it would be slower on the Spresense than the Nano?