1
我下面OpenCV的教程http://opencv-python-tutroals.readthedocs.io/en/latest/py_tutorials/py_calib3d/py_calibration/py_calibration.html攝像機標定OpenCV的蟒蛇
而是用一個棋盤運行它,我接到了一個LAS文件我的三維點座標。這裏是我的代碼:
import cv2
import numpy as np
obj_point = [(630931.35,4833642.85,157.67),(630948.03,4833662.76,73.94), (631156.3, 4833904.18, 43.89),(630873.71, 4833790, 44.85), (631381.3, 4834152.6, 79.41)]
img_point = [(1346.82,843.206),(1293.03,808.146),(1041.92, 585.168), (1150.21, 894.724), (756.993,345.904) ]
obj_point = np.array(obj_point,'float32')
img_point = np.array(img_point,'float32')
ret, mtx, dist, rvecs, tvecs = cv2.calibrateCamera(obj_point, img_point, (1125, 1725),None,None)
我得到了以下錯誤消息:初始內在基質必須在功能上cvCalibrateCamera2
THX中 指定
對於非平面校正臺提前!
嘿謝謝你的回答!你知道「ret」的價值是什麼嗎?它是否重新投影錯誤? –
閱讀[這裏](http://stackoverflow.com/questions/29628445/meaning-of-the-retval-return-value-in-cv2-calibratecamera)...簡短版本:是的;) – PSchn
dam then there is我猜想我的3d點有些問題。我的ret = 357 .. –