Module Import alias identifier Import alias Import alias ImportFrom alias Assign NameStore Str If CompareEq NameLoad Str body Import alias alias ImportFrom alias Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Slice Num Str ListLoad Str Str Str Assign NameStore Call NameLoad NameLoad TryExcept body Assign NameStore SubscriptLoad NameLoad Index Num handlers ExceptHandler body Assign NameStore Str Assign NameStore Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr Str Num Assign NameStore TupleLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr TupleLoad Call AttributeLoad NameLoad attr NameLoad Num AttributeLoad NameLoad attr Assign SubscriptStore NameLoad ExtSlice Slice Slice Num Call AttributeLoad AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr attr Num Num AugAssignMult NameStore NameLoad Assign NameStore ListLoad Assign NameStore ListLoad Assign TupleStore NameStore NameStore TupleLoad Num Num For NameStore NameLoad body Print BinOpMod Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Num Assign TupleStore NameStore NameStore SubscriptLoad AttributeLoad NameLoad attr Slice Num Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If NameLoad body Assign NameStore TupleLoad BinOpAdd AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad TupleLoad Num Num TupleLoad Num Num NameLoad If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad Assign TupleStore NameStore NameStore NameStore Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Print Str Continue Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Num Num Expr Call AttributeLoad NameLoad attr NameLoad Print Str Assign TupleStore NameStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad TupleLoad NameLoad NameLoad Print Str NameLoad Print Str NameLoad Print Str Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr
N/A N/A numpy np N/A cv2 N/A os common splitfn N/A USAGE 
USAGE: calib.py [--save <filename>] [--debug <output path>] [--square_size] [<image mask>]
 N/A N/A __name__ __main__ N/A N/A sys getopt glob glob N/A N/A args img_mask N/A N/A getopt getopt N/A N/A sys argv N/A 1 N/A save= debug= square_size= N/A args N/A dict args N/A N/A N/A img_mask N/A img_mask N/A 0 N/A N/A N/A N/A img_mask ../cpp/left*.jpg N/A img_names N/A glob img_mask N/A debug_dir N/A N/A args get --debug N/A square_size N/A float N/A N/A args get --square_size 1.0 N/A pattern_size N/A 9 6 N/A pattern_points N/A N/A np zeros N/A N/A N/A np prod pattern_size 3 N/A np float32 N/A N/A pattern_points N/A N/A N/A 2 N/A N/A N/A N/A N/A np indices pattern_size T reshape -1 2 N/A pattern_points square_size N/A obj_points N/A N/A img_points N/A N/A N/A h w N/A 0 0 N/A fn img_names N/A N/A N/A processing %s... fn N/A img N/A N/A cv2 imread fn 0 N/A N/A h w N/A N/A img shape N/A 2 N/A N/A found corners N/A N/A cv2 findChessboardCorners img pattern_size N/A found N/A N/A term N/A N/A N/A cv2 TERM_CRITERIA_EPS N/A cv2 TERM_CRITERIA_COUNT 30 0.1 N/A N/A N/A cv2 cornerSubPix img corners N/A 5 5 N/A -1 -1 term N/A debug_dir N/A N/A vis N/A N/A cv2 cvtColor img N/A cv2 COLOR_GRAY2BGR N/A N/A N/A cv2 drawChessboardCorners vis pattern_size corners found N/A N/A path name ext N/A splitfn fn N/A N/A N/A cv2 imwrite N/A %s/%s_chess.bmp N/A debug_dir name vis N/A N/A found N/A N/A chessboard not found N/A N/A N/A N/A img_points append N/A N/A corners reshape -1 2 N/A N/A N/A obj_points append pattern_points N/A ok N/A N/A rms camera_matrix dist_coefs rvecs tvecs N/A N/A cv2 calibrateCamera obj_points img_points N/A w h N/A RMS: rms N/A camera matrix:
 camera_matrix N/A distortion coefficients:  N/A N/A dist_coefs ravel N/A N/A N/A cv2 destroyAllWindows