Friday, August 18, 2017

Realtime depth estimation using monocular camera

Just for playing around, I did a small modification to the from the github of CVPR 2017 paper "Unsupervised Monocular Depth Estimation with Left-Right Consistency" (original source code:, so that it takes input image directly from a camera. To retrieve images from the camera without losing much performance, I refer to the articles from here and here.

I used i7 6700K + Nvidia GTX 970 + Logicool webcam C910:

It appears that although the trained model was Kitti, which is quite different from the scene from my apartment window, it still worked to a certain extent. If you are interested, you can download the modification: and a small utility for retrieving the image:

To run the modification, download the original code and the ready-to-use model by following the instruction from the original Author ( here ). Then copy and to the same folder as the Finally, execute:
$ python ./ --checkpoint_path ./model/model_kitti

Note that it requires Python 2.7, TensorFlow 1.x, OpenCV >= 2.4 (I used OpenCV 3.2), and of course, a camera.

That's all :)

1 comment:

  1. I just read your article and watched the video that you have provided in this article. You have explained the monocular cameras in the best possible way and I found this article very informative for monocular user. Those who are looking to buy the best monoculars for their needs, it is suggested to take a look at this list of monoculars where you will find the best collection and tips to buy the best one for your needs