OpenCV "The function is not implemented. Rebuild the library with Windows"

11,516

Solution 1

I had the same issue too. Despite they were installed before, I've installed them again via:

pip install opencv-python 
pip install opencv-contrib-python 

and problem solved.

Solution 2

I was having the same problem under python v3.7.9

I typed pip list and I had opencv-python-headless version 4.4.0.44

I looked under GUI tag and VTK support: NO

I typed the command @Samet suggested and now I have

opencv-contrib-python           4.4.0.46
opencv-python                   4.4.0.46
opencv-python-headless          4.4.0.44

It is working now but I don't know if I should leave 'opencv-python-headless'. As @Fabio Baldissera said he only installed opencv-contrib-python and it worked but I don't know if you would want to end up with opencv-python and opencv-contrib from two different versions, I would not recommend it.

I'm able to show a RTSP stream now.

Share:
11,516
Cakkaphong Khangsri
Author by

Cakkaphong Khangsri

Updated on July 02, 2022

Comments

  • Cakkaphong Khangsri
    Cakkaphong Khangsri almost 2 years

    I see problem unsolvable.I get this error when I try to import numpy

    import cv2
    import numpy as np
    
    img=cv2.imread('image.jpg',1)
    cv2.imshow('image', img)
    cv2.waitkey()
    cv2.destroyAllWwindows()
    

    when I run attribute imread is not working

    cv2.error: OpenCV(3.4.1) C:\projects\opencv-python\opencv\modules\highgui\src\window.cpp:636: error: (-2) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function cvShowImage

    Please help, Python version 3.6

    OpenCV version :3.4.1

    matplotlib version : 2.2.2

  • Fabio Baldissera
    Fabio Baldissera over 3 years
    Installing opencv-contrib-python did the trick for me. Thanks.