I have found the following code on this website:
import os
import os.path
import cv2
import glob
import imutils
CAPTCHA_IMAGE_FOLDER = \"generated_captcha_im
This is because of opencv-python version 4.0.0. If you want to fix this without changing your code then downgrade opencv-python to version 3.4.9.31
Uninstall opencv-python
pip uninstall opencv-python
Install opencv-python==3.4.9.31
pip install opencv-python==3.4.9.31
If facing issue with function 'pointSetBoundingRect', you need to install 'opencv-python-headless'
pip install opencv-python-headless==3.4.9.31