Chapter 12 範例
OpenCV install

(需用系統管理員啟動:Error?)(base) C:\WINDOWS\system32>conda install -c https://conda.anaconda.org/menpo opencv3
Solving environment: failed
UnsatisfiableError: The following specifications were found to be in conflict:
- opencv3
- zict
Use "conda info " to see the dependencies for each package.

(需用系統管理員啟動)Anaconda Prompt>conda install -c conda-forge opencv

showimage1.py(執行時間~數秒)
Python 與OpenCV 基本讀取、顯示與儲存圖片教學- G. T. Wang
cv2.namedWindow("ShowImage3", cv2.WINDOW_NORMAL)
image3 = cv2.imread("media_jdwang\\IMG_0545.jpeg", cv2.IMREAD_COLOR)
image4 = cv2.imread("media_jdwang\\IMG_0545.jpeg", cv2.IMREAD_GRAYSCALE)

saveimage1.py(執行時間~數秒)
basicplot1.py

detectFace1.py

error: C:\ci\opencv_1512688052760\work\modules\objdetect\src\cascadedetect.cpp:1698: error: (-215) !empty() in function cv::CascadeClassifier::detectMultiScale
=>檔案總管(search "haarcascade_frontalface_default.xml")
=>C:\ProgramData\Anaconda3\pkgs\opencv-3.4.4-py36hb76ac4c_1203\Library\etc\haarcascades\haarcascade_frontalface_default.xml
=>casc_path = "C:\\ProgramData\\Anaconda3\\pkgs\\opencv-3.4.4-py36hb76ac4c_1203(你可能不一樣?)\\Library\\etc\\haarcascades\\haarcascade_frontalface_default.xml" #imagename = cv2.imread("media\\person1.jpg")
#imagename = cv2.imread("media\\person3.jpg")
imagename = cv2.imread("media\\person8.jpg")

saveFace1.py
=>casc_path = "C:\\ProgramData\\Anaconda3\\pkgs\\opencv-3.4.4-py36hb76ac4c_1203(你可能不一樣?)\\Library\\etc\\haarcascades\\haarcascade_frontalface_default.xml"
imagename = "media\\person1.jpg"
imagename = "media\\person3.jpg"
imagename = "media\\person8.jpg"

detectFace1.py
cv2.namedWindow("facedetect", cv2.WINDOW_NORMAL)
cv2.resizeWindow("facedetect", 1024, 768);

camPicture1.py
facelock1.py

Tesseract:驗證碼辨識
(Download)https://digi.bib.uni-mannheim.de/tesseract/
(tesseract-ocr-setup-3.05.00dev)
(FileNotFoundError: [WinError 2] 系統找不到指定的檔案。?)ocr1.py
OCR_Test_jdwang2019_1_5.png