随笔分类 - openmv学习
openmv
摘要:import sensor, time, image sensor.reset() # Initialize the camera sensor. sensor.set_pixformat(sensor.GRAYSCALE) # or sensor.GRAYSCALE sensor.set_fram
阅读全文
摘要:sensor.reset() # Initialize the camera sensor. sensor.set_pixformat(sensor.GRAYSCALE) # or sensor.GRAYSCALE sensor.set_framesize(sensor.B128X128) # or
阅读全文
摘要:移植: 1.import display 导入库 2.sensor.set_framesize(sensor.QQVGA2) 设置分辨率,lcd的分辨率是160*128,如果原代码中是QQVGA,也可以不用改 3.lcd = display.SPIDisplay() lcd初始化 4.sensor.
阅读全文
摘要:这里仅讨论识别人脸,先不讨论识别不同的人脸 本例程的目的是利用haar算子实现人脸识别。 这个例子展示了OpenMV Cam的内置人脸检测功能。 人脸检测通过在图像上使用Haar Cascade特征检测器来工作。 haar级联是 一系列简单的区域对比检查。 对于内置的前表面探测器,有25个阶段的检查
阅读全文
摘要:find_circles识别圆 find_circles(roi: Tuple[int, int, int, int] | None = None, x_stride=2, y_stride=1, threshold=2000, x_margin=10, y_margin=10, r_margin=
阅读全文
摘要:OpenMV采用的是单目摄像头,想要实现测距,就需要选参照物,利用参照物的大小比例来计算距离。 原理:实际长度和摄像头里的像素成反比 即:距离 = 一个常数/直径的像素 K1=5000#the value should be measured K2=0.16 ... Lm = (b[2]+b[3])
阅读全文
摘要:image.find_blobs(thresholds, roi=Auto, x_stride=2, y_stride=1, invert=False, area_threshold=10, pixels_threshold=10, merge=False, margin=0, threshold_
阅读全文
摘要:thresholds = [ (30, 100, 15, 127, 15, 127), # generic_red_thresholds (30, 100, -64, -8, -32, 32), # generic_green_thresholds (0, 30, 0, 64, -128, 0),
阅读全文