Generic Sensor Raw Data to Keras Classification

Kind of connected to this thread with @matkelcey, but on a much simpler level Expert Mode: Adding Extra Layers

For my students I want to make a generic raw data Keras classification model that they can use for any/many combinations of sensor data. Assume uploading, labelling etc of the data is worked out, my question for @louis @aurel or anyone is. The standard Keras classification default model is:

Input–> 20 dense neuron layer -->10 dense neuron layer → Output.

Anyone have an expert mode working Keras classification model that will cover many different types of sensor inputs? I am fine my students adding or reducing layers, just want a more flexible starting point. Any suggestions?

My students might have projects where the sensors are: (or any combination of the sensors I teach )

  1. 5 flexible sensors.

  2. Pixy2 Camera which an give shade, x, y, width, height and a few other data points.

  3. temperature, humidity, light, wind speed…

  4. 2-4 various air quality sensors such as CO2, VOC, Ozone

  5. motion (x, y only) with several touch sensors

  6. GPS with Acceleration

If raw data to Keras classification is the wrong starting point can someone suggest a better model?

So this is interesting, both the raw-data Keras Expert mode Classification and the default Motion program both use the same basic model input–>20 dense–>10 dense–>Output

.

FOMO is a whole different ball game, but for Vision here are the two main ones I have found. (Not relevant for sensor information, just thought I would show these since I showed the other two models)

From really old messing around with the Portenta, the board can handle much more than 30 dense layers. See Image of 2020 crash tests (Has both cores of the PortentaH7, also the Seeedstudio XIAO, Particle Argon, Arduino Nano33IoT and Arduino Nano33BLESense). Note: These tests were done without any quantization, and not even done with EdgeImpulse. I haven’t even touched these files here for 2 years.

Now someone must have ran the EON tuner with a Motion model and come up with many more models that would be a good starting point for sensor data. I only have one main Motion model (My class trained a Nano33BleSense to detect these letters W.O.R.D.S and a few other things. 2 part video starting here) so I am going to run the ION tuner on that model and see what I get.

I am really looking for a good complex larger model that my students can then reduce in size if needed for their own sensor analysis. I don’t think speed is very relevant for most of my student’s sensor ML projects. Accuracy is porbably the biggest issue.

Suggestions always welcome!

Here is something I found at this site for motion. Not saying this will work with EdgeImpulse and my Arduino, just showing what others are using.

.

.

My first look at the EON tuner results seems to just be adding dropout to the dense layers. I have changed the settings and will try EON again.

Let’s change the tone of this thread slightly. No High School student of mine is ever going to add a Keras layer to a Neural Network, but if I tell them to improve a model by deleting or duplicating a layer that is already part of the model, they will be all over that.

So new question, what is the most sensible set of Keras layers that uses every EdgeImpulse EON tuner supported layers?

The Add Layer button mentions that I can have access to the full set of Keras Layers, but are they compatible with the EON Tuner or is only the set mentioned in this image: Dense, 1D Conv, 2D Conv, Reshape, Flatten, Dropout?

Reminder, I want the most amount of different Keras layers that make an OK model of any set of Sensor data, that still works with the EON tuner. Any suggestions.

This is my baseline motion model using the standard 20 dense–>10 dense. So I guess whatever I /we come up with should be at least as OK as this model, I don’t mind it it is bigger and slower, just would have to work on the PortentaH7 M7 core.

In case anyone is interested here is the list of all Keras API Layers

1 Like

So here is one big ugly neural network that doesn’t really make any sense for sensor data but works fine. The idea is for students to prune it down, or make it bigger and then get it to work on whatever microcontroller they are using.

Any opinions? Anyone think this activity is a waste of time?