Skip to content
Advertisement

module ‘cv2.cv2’ has no attribute ‘dnn_superres’

I am trying to upscale image (performing super resolution) using OpenCV, but I am getting this error that module ‘cv2.cv2’ has no attribute ‘dnn_superres’. Any help would be greatly appreciated.

I am using 4.4.0.44 OpenCV version. Here is the code section.

JavaScript

Advertisement

Answer

In case you are using python3, you need to download opencv with pip3

First uninstall opencv:

JavaScript

Then install latest version of opencv with pip3:

JavaScript
User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement