Commit 82646a7f authored by Vincent POLLET's avatar Vincent POLLET
Browse files

Merge branch 'doc' into 'master'

Doc

See merge request !12
parents 80703b8f d514254a
Pipeline #47321 failed with stages
in 5 minutes and 22 seconds
......@@ -61,24 +61,24 @@ class Camera:
#==============================================================================
class CameraPair:
""" This class represents the camera view in 3D space together with its
projection matrix and lens distortion. In addition, 4 marker points
can be added to perform 2D perspective transformations.
""" This class represents the camera view in 3D space together with its
projection matrix and lens distortion. In addition, 4 marker points
can be added to perform 2D perspective transformations.
Attributes
----------
camera_matrix : :obj:`numpy.ndarray`
Camera projection matrix, according to OpenCV's standards.
dist_coeffs : :obj:`numpy.ndarray`
Distortion coefficeints, according to OpenCV's standards.
R : :obj:`numpy.ndarray`
Rotation matrix relative to left stereo camera.
T : :obj:`numpy.ndarray`
Translation vector relative to left stereo camera.
markers : :obj:`numpy.ndarray`
Four points in 2D image coordinates that can be maapped
to another set of four points in a different camera view.
"""
Attributes
----------
camera_matrix : :obj:`numpy.ndarray`
Camera projection matrix, according to OpenCV's standards.
dist_coeffs : :obj:`numpy.ndarray`
Distortion coefficeints, according to OpenCV's standards.
R : :obj:`numpy.ndarray`
Rotation matrix relative to left stereo camera.
T : :obj:`numpy.ndarray`
Translation vector relative to left stereo camera.
markers : :obj:`numpy.ndarray`
Four points in 2D image coordinates that can be maapped
to another set of four points in a different camera view.
"""
def __init__(self, camera_left, camera_right):
self.camera_matrix_l = camera_left.camera_matrix
......
......@@ -41,7 +41,7 @@ class StereoParameters:
erode = False,
inpaint = False):
self.algorythm = algorythm
self.algorithm = algorithm
# OPENCV_SGBM
self.min_disparity = min_disparity
......
......@@ -76,7 +76,7 @@ def stereo_match(img_l, img_r, camera_pair, stereo_parameters=StereoParameters()
#block match
if stereo_parameters.algorythm == stereo_parameters.STEREO_CV_SGBM:
if stereo_parameters.algorithm == stereo_parameters.STEREO_CV_SGBM:
stereo = cv.StereoSGBM_create(minDisparity = stereo_parameters.min_disparity,
numDisparities = stereo_parameters.num_disparities,
......@@ -96,7 +96,7 @@ def stereo_match(img_l, img_r, camera_pair, stereo_parameters=StereoParameters()
else:
raise Exception('Unknown stereo algorythm')
raise Exception('Unknown stereo algorithm')
# inpaint depth map holes
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment