Rendering issue #7
Comments
I think you need to set the "--xoffset" flag (if this is a rectified left-right stereo pair), and possibly also the "--yoffset" and "--zoffset" flags if the camera motion is not horizontal. Those flags tell the binary what the camera motion is between the left and right views. They are zero by default, and so you will get degenerate results if you do not set at least "--xoffset". I have just added an example to demonstrate in the examples subdirectory. |
Note also that if you want to render multiple images, you can provide multiple offsets in the "--render_multiples" argument (e.g, "--render_multiples="-10,0,10"). |
Thank you for your reply! Also I'd like to mention that when I try to render multiple images, it fails with (likely) out-of-memory error (I use Google Colab GPU). Is there any possible way to fix it? |
Interesting -- I haven't tested on a Colab GPU. I guess the backup is to render a single image and call the binary multiple times. However, I am unsure of why you would run out of memory, though I will give it some thought. Please feel free to propose a fix if you uncover the issue. |
Can you explain what the offset values in render_multiples mean? Are they the offsets in world coordinates from camera 0? |
The values in --render_multiples indicate viewpoint offset multipliers on the translation vector indicated by [--xoffset, --yoffset, --zoffset]. That is, if render_multiple = 2, then the camera is moved to the location "reference_viewpoint + 2 * [xoffset, yoffset, zoffset]". |
@Gpoxolcku I came up with an error like "Graphdef cannot be larger than 2GB in tensorflow", if it's also yours, just add "tf.reset_default_graph" after sess.run will fix this problem. |
Hello. I was googeling around for a way to try out this code and I saw your comment about a Colab notebook. Is this Google Colab Notebook still available? May I try it out? Thanks in advance. |
Hi, friend!
Am I getting it right that the "render" flag's purpose is to allow output of rendered extrapolated stereopair images? No matter of the "render_multiples" values, the rendering result is the cropped reference image. Here's an example of the command I use to launch the tool:
python mpi_from_images.py --image1=/path/to/left.png --image2=/path/to/right.png --output_dir=./output/ --render_multiples=10 --render=True
Thanks in advance!
The text was updated successfully, but these errors were encountered: