vsitzmann / shapenet_renderer

A clean, compact renderer for spherical images of shapenet objects in blender <2.8.
MIT License
75 stars 18 forks source link

This is a compact implementation of a batched OBJ- and PLY-renderer in blender. The inspiration was drawn from the "Stanford Shapenet Renderer". This code can be used to render datasets such as the ones used in the "Scene Representation Networks" paper.

It assumes blender < 2.8, as it uses the blender-internal renderer.

To render a batch of ply files in parallel, use the "find" command in conjunction with xargs:

find ~/Downloads/02691156/ -name *.ply -print0 | xargs -0 -n1 -P1 -I {} blender --background --python shapenet_spherical_renderer.py -- --output_dir /tmp --mesh_fpath {} --num_observations 50 --sphere_radius 1 --mode=train