Select to view content in your preferred language

Training TF lite model for Survey123: Difficulties getting demo to work.

1199
3
Jump to solution
02-07-2022 02:25 AM
7177
by
Occasional Contributor

Hi,
I'm in the process of wrapping my head around the  TensorFlow-Lite in Survey using the respective ArcGIS lessonhttps://learn.arcgis.com/en/projects/train-a-model-to-identify-street-signs/#train-a-model 

trying to get this Notebook to run: 

SignImageClassificationModel - Übersicht (arcgis.com)

I asked for help over at 

Train a model to identify street signs: Trouble running demo notebook - ArcGIS Survey123 (esri.com)

and got help fixing some issues relating to some missing python modules, but got stuck later on. 

 The  notebook still fails at step 8. where the trained model is being saved for deployment. I can't get the save(() method for the FeatureClassifier object to work. 

I'd be grateful for any kind of assistance you might be able to give!

(Edfited for clarity and brevity)

Cheers!

Screenshots of the error I get attached below.  

 

0 Kudos
1 Solution

Accepted Solutions
7177
by
Occasional Contributor

Thank you for the quick response!

 

I'm gonna try and run it on the old runtime and API and will report back!

 These example Notebooks would be a great resource, if they were kept up-to-date, so those with little Python experience could learn from them.

Yes indeed. Don't know how else to understand AI inference on edge devices with survey. Can't imagine though, that everyone who wants to use  use this feature are forced to run obsolete version of the API cause the switch to tensor flow doesn't work or the save method is broken? That can't be right. (:

 

Cheers!

 

Cheers! 

View solution in original post

0 Kudos
3 Replies
PeterKnoop
MVP Regular Contributor

I feel your frustration. These example Notebooks would be a great resource, if they were kept up-to-date, so those with little Python experience could learn from them. As it is, these Notebooks work briefly when they first come out, and then most stop working completely due to updates in the ArcGIS API for Python and/or the ArcGIS Online Notebook environment. Those updates usually trigger issues that someone new to Python likely does not have the right skills yet to diagnose, so they waste time and get nowhere. It would be nice if Esri committed to keeping the examples up-to-date.

As of a few weeks ago, the missing step to getting SignImageClassificationModel working was to ensure you ran it using the correct, older runtime in an ArcGIS Online Notebook. So whether you download and then upload the Notebook, used Save As, or are cutting-and-pasting into your own Notebook, go to your Notebook's Settings, and change the runtime to "ArcGIS Notebook Python 3 Advanced with GPU support - 4.0".  (See Specify the runtime of a notebook.)

Once you've done that, then following the steps in the Notebook exactly -- installing version 1.8.4 of the API, restarting the kernel afterwards -- should result in a fully working Notebook.

7177
by
Occasional Contributor

Thank you for the quick response!

 

I'm gonna try and run it on the old runtime and API and will report back!

 These example Notebooks would be a great resource, if they were kept up-to-date, so those with little Python experience could learn from them.

Yes indeed. Don't know how else to understand AI inference on edge devices with survey. Can't imagine though, that everyone who wants to use  use this feature are forced to run obsolete version of the API cause the switch to tensor flow doesn't work or the save method is broken? That can't be right. (:

 

Cheers!

 

Cheers! 

0 Kudos
7177
by
Occasional Contributor

I can confirm that installing arcgis 1.8.4 and running it with GPU support - 4.0 runtime does the trick. Thank you very much for helping out! Cheers!

0 Kudos