Synthetic dataset creator using Blender Python API and poliigon material converter.
Python 3.8 or later with all requirements.txt dependencies installed. To install run:
$ pip install -r requirements.txtObjects, Materials + examples
https://drive.google.com/drive/folders/1IlFDUHxvjXrwdo9GdHM764n9HKwnzfml?usp=sharing
Renders a set of scenes built from a json file.
You can use --resume to continue an interrupted render.
$ blender -b --python render.py -- render.json [--resume]To generate the required folder structure run this command
It will generate the bdataset dir in the parent directory using the output
$ python dataset.pyclasses: list containing the classes of the objectsbatches: a list containing scene informationimports: a list containing imports (objects, materials) tuplesobject/fbx: use object if you import an obj file and fbx if you import an fbx filepath: path to the object filename: the name of the object, used in blender as an idclass: object classposition: position of the objectrotation: rotation of the objectscale: scale of the objectseed: used to randomize vertices, 0 if not used
materials: a list of materials to assign to the objectpath: path to the material filename: name of the material
scene: contains scene configurationscamera:position: initial position of the camerarotation: initial rotation of the camera
lights: list of light configurationstype:SUN,POINT, other Blender light types.position: position of the lightrotation: rotation of the lightenergy: intensity of the light
render: render configurationpath: the output directory pathresolution: the resolution of the image,witdh=height=resolutiontype: "basic", "flow", "stereo": basic and stereo use the eevee engine. optical flow needs cycles next you should use either views for a static render or frames if you use an animation fileviews:x: angles on the x axis [start, stop(not included), step]y: angles on the y axis [start, stop(not included), step]z: angles on the z axis [start, stop(not included), step]
frames: frames to render an animation [start, stop(not included), step]