erget / StereoVision

Library and utilities for 3d reconstruction from stereo cameras.
http://erget.github.io/StereoVision
GNU General Public License v3.0
649 stars 268 forks source link

int concatenate issue #35

Closed wuxiaohua1011 closed 5 years ago

wuxiaohua1011 commented 5 years ago

on line 86 and 87 in stereo_camera.py, the code left_frame = frame[:, : width/2, :] and right_frame = frame[:, width/2:, :] should be
left_frame = frame[:, :int(width/2), :] and right_frame = frame[:, int(width/2):, :]

i have Macbook Pro and its reporting TypeError: slice indices must be integers or None or have an __index__ method without those

erget commented 5 years ago

Seems reasonable. Would you like to send a PR that implements this? This might also be a Python2 vs Python3 issue, as Python2 probably implicitly casts floats...