calculate the disparity from a stereo image using PSMNet
A simple python wrapper for disparity calculation.
The PSMNet is from: https://github.com/JiaRenChang/PSMNet
The code is Python 2, but Python 3 compatible.
for python2: pip install SMDTest
for python3: pip3 install SMDTest
from PSMNet import smd
disparity_img = smd.calculate_disparity(imgL,imgR)
corrected_img = smd.correct_img(imgR,disparity_img)
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.