haverland / Tenth-of-step-of-a-meter-digit

Apache License 2.0
10 stars 5 forks source link

Installation problems following Cookbook running the jupyter notebook (on Windows) #14

Open hassdevil opened 3 weeks ago

hassdevil commented 3 weeks ago

Hi haverland, hi all i try to create my own model but i am struggeling with the howtos. I have an analog pressure gauge and i want to train a new model. i have already got the pictures and the labeled output. I have installed python on windows10 and now i wondering how to proceed. I have installed both https://github.com/haverland/collectmeterdigits and https://github.com/haverland/https://github.com/haverland/collectmeteranalog. In your howto you are refering to the Digital Meter model creation. I do need them for my analog gauge? Can you tell me how to proceed with the howto?

haverland commented 2 weeks ago

I think the gauge is more like a pointer. So I would use the collectmeteranalog.

Under https://jomjol.github.io/AI-on-the-edge-device-docs/Learn-models-with-your-own-images/ is the learning described.

But in your special case I suggest following proceed:

1.) Use the https://github.com/jomjol/neural-network-analog-needle-readout for training a model.

haverland commented 2 weeks ago

1.) Run the Notebook Train_CNN_Ana-Class100_S2.ipynb. You will need to get a trained *_best.h5 model once. Save it for later use 2.) Remove the images in /data_raw_all 3.) Add your own images (should be 1-10 for each value 4.) Use Train_CNN_Ana-Class100_S2.ipynb 5.) after defining the model and before Training add a code block with: model = keras.models.load_model("saved_model.h5") 6.) run the complete model again.

You will in this case use the transfer learning method (https://www.tensorflow.org/tutorials/images/transfer_learning). You use as first the analog pointer images to the a model. Because you have not much images you use the model to retrain it on your images.

haverland commented 2 weeks ago

after all the _q.tflite model can be uploaded to the esp32 device.