cfernandezlab / CFL

Tensorflow implementation of our end-to-end model to recover 3D layouts. Also with equirectangular convolutions!
GNU General Public License v3.0
104 stars 18 forks source link

layout 3d #19

Open rshivansh opened 3 years ago

rshivansh commented 3 years ago

Hello, thanks for the code!

a small doubt, I followed the 2Dto3D python notebook and understood how to get the wireframe. can you please tell me what to change to get the room layouts in 3D like the teaser gif you have in this repo?

Thanks

cfernandezlab commented 3 years ago

Hi! Thanks for your comment!

In the provided python notebook you see how to get the room corners in 2D and 3D respectively. Using the corners, you can easily define the room planes (walls, ceiling and floor).

For every pixel in the image, you need to intersect its corresponding 3D ray with the room plane it belongs to in order to get the actual 3D point. For the color, you just use the RGB value of the pixel. Then, you can create a point cloud using your favorite library (eg. trimesh) and visualize it.

I hope it helps :)

rshivansh commented 3 years ago

thanks, it helps! I am also following your scene understanding repo for more details. do you have the code for the color part?