Esri / raster-deep-learning

ArcGIS built-in python raster functions for deep learning to get you started fast.
Apache License 2.0
190 stars 88 forks source link

Same error with both Land Classification and Coconut Tree identification. #26

Closed billharbert closed 4 years ago

billharbert commented 4 years ago

Hello,

Since upgrading to ArcPro 2.5.0 and Tensorflow 2.0.0 neither of the deep learning examples are working. I have the appropriate licenses and modules and these worked before the update. The error I am getting with both (after loading the .emf file) is given below:

ERROR 002667 Unable to initialize python raster function with scalar arguments. [c:\program files\arcgis\pro\Resources\Raster\Functions\System\DeepLearning\ObjectDetector.py] Traceback (most recent call last): File "c:\program files\arcgis\pro\Resources\Raster\Functions\System\DeepLearning\ObjectDetector.py", line 84, in initialize self.child_object_detector.initialize(model, model_as_file) File "c:\program files\arcgis\pro\Resources\Raster\Functions\System\DeepLearning\Templates\TemplateBaseDetector.py", line 44, in initialize self.load_model(model_path) File "c:\program files\arcgis\pro\Resources\Raster\Functions\System\DeepLearning\TensorFlow\ObjectDetectionAPI.py", line 53, in load_model od_graph_def = tf.GraphDef() AttributeError: module 'tensorflow' has no attribute 'GraphDef'

Unable to initialize python raster function with scalar arguments.

The Esri model definition parameter value can be an Esri model definition JSON file (.emd), a JSON string, or a deep learning model package (.dlpk). A JSON string is useful when this tool is used on the server so you can paste the JSON string, rather than upload the .emd file. The .dlpk file must be stored locally. It contains the path to the deep learning binary model file, the path to the Python raster function to be used, and other parameters such as preferred tile size or padding.


Any suggestions to correct this would be greatly appreciated.

Thanks!

lingtangraster commented 4 years ago

@billharbert Hi Bill, currently we only support TensorFlow 1.14.0. Thanks for reporting this issue, we will look into supporting TensorFlow 2.0.0 in near future.

billharbert commented 4 years ago

Thank you. Are you saying that this example works with ArcPro 2.5.0 and older versions of Tensorflow?

lingtangraster commented 4 years ago

@billharbert Please downgrade Tensorflow to 1.14.0.

billharbert commented 4 years ago

Hello and thank you. I can confirm exactly what you said, which is that these examples work with ArcPro 2.5.0 with Tensorflow 1.14.0 installed. Thank you for your expert and quick response.