Ask Your Question

Revision history [back]

AttributeError: 'dnn' object has no attribute 'writeTextGraph'

Hello, Im trying to load a pretrained Tensorflow model using OpenCV by following the steps in the below link: https://github.com/opencv/opencv/wiki/TensorFlow-Object-Detection-API When i try to generate a text representation of the graph by using the script tf_text_graph_ssd.py ,Im getting the error AttributeError: 'dnn' object has no attribute 'writeTextGraph' . I have the OpenCv 3.4 installed on my machine and I checked that dnn doesnt have an attribute or method under that name by running dir(dnn) in python after importing the library . When I chekced the online documentation ,I could find it exists : https://docs.opencv.org/trunk/d6/d0f/group__dnn.html#ga0c3f216f5f858efdef44b68636133dff but not in opencv python . I dont know what I am missing here .How can I fix the error ?

Thanks Ayad

click to hide/show revision 2
retagged

updated 2018-09-17 09:51:59 -0500

berak gravatar image

AttributeError: 'dnn' object has no attribute 'writeTextGraph'

Hello, Im trying to load a pretrained Tensorflow model using OpenCV by following the steps in the below link: https://github.com/opencv/opencv/wiki/TensorFlow-Object-Detection-API When i try to generate a text representation of the graph by using the script tf_text_graph_ssd.py ,Im getting the error AttributeError: 'dnn' object has no attribute 'writeTextGraph' . I have the OpenCv 3.4 installed on my machine and I checked that dnn doesnt have an attribute or method under that name by running dir(dnn) in python after importing the library . When I chekced the online documentation ,I could find it exists : https://docs.opencv.org/trunk/d6/d0f/group__dnn.html#ga0c3f216f5f858efdef44b68636133dff but not in opencv python . I dont know what I am missing here .How can I fix the error ?

Thanks Ayad

click to hide/show revision 3
retagged

updated 2018-09-17 09:52:15 -0500

berak gravatar image

AttributeError: 'dnn' object has no attribute 'writeTextGraph'

Hello, Im trying to load a pretrained Tensorflow model using OpenCV by following the steps in the below link: https://github.com/opencv/opencv/wiki/TensorFlow-Object-Detection-API When i try to generate a text representation of the graph by using the script tf_text_graph_ssd.py ,Im getting the error AttributeError: 'dnn' object has no attribute 'writeTextGraph' . I have the OpenCv 3.4 installed on my machine and I checked that dnn doesnt have an attribute or method under that name by running dir(dnn) in python after importing the library . When I chekced the online documentation ,I could find it exists : https://docs.opencv.org/trunk/d6/d0f/group__dnn.html#ga0c3f216f5f858efdef44b68636133dff but not in opencv python . I dont know what I am missing here .How can I fix the error ?

Thanks Ayad