python版本:3.6.5 opencv版本:3.2.0 使用的是jupyter notebook 源代码如下: import cv2 import numpy as np import matplotlib.pyplot as plt %matplotlib inline # Feature set containing (x,y) values of 25 known/training data trainData = np.random.randint(0,100,(25,2)).ast…