Output selection

In the MINERVAS system, there are several rendering output we support:

  • RGB renderings
  • Normal map
  • Instance map
  • Semantic map
  • Depth map
  • Trajectory map

Function list

PixelProcessor has several functions for selecting different output.

FunctionDescription
gen_normal(distort=0)Generate normal map. (distort: int)
gen_instance(distort=0)Generate intance map. (distort: int)
gen_semantic(distort=0)Generate semantic map. (distort: int)
gen_depth(distort=0, noise=0)Generate depth map. (distort: int, noise: int)
gen_traj(**params)Generate trajectory visualization (top-down view). (params: dict: parameter list from each type of Trajectory)
gen_albedo(distort=0)Generate albedo map. (distort: int)

Examples:

Normal map

Output format:

  1. 3 channel * 8 bit
  2. Suppose r, g, b represent three color channels
    • [-1, 1] range of normal direction value are mapped to [0, 255]

Usage:

from ksecs.ECS.processors.pixel_processor import PixelProcessor
class NormalDsl(PixelProcessor):
    def process(self, **kwargs):
        self.gen_normal(distort=1)

Instance map

Output format:

  1. 1 channel * 16 bit
  2. Each pixel value represent a instance_id.
    • The mapping of pixel value and instance id can be found in instance_map.json.

Usage:

from ksecs.ECS.processors.pixel_processor import PixelProcessor
class InstanceDsl(PixelProcessor):
    def process(self, **kwargs):
        self.gen_instance(distort=0)

Semantic map

Output format:

  1. 1 channel * 16 bit
  2. Each pixel value represents a label_id

Usage:

from ksecs.ECS.processors.pixel_processor import PixelProcessor
class SemanticDsl(PixelProcessor):
    def process(self, **kwargs):
        self.gen_semantic(distort=0)

Depth map

Output format:

  1. 1 channel * 16 bit

Usage:

from ksecs.ECS.processors.pixel_processor import PixelProcessor
class DepthDsl(PixelProcessor):
    def process(self, **kwargs):
        self.gen_depth(distort=0, noise=1)

Trajectory map

Visualize trajectory in the top-down view rendering result. Customized trajectory and bow-shape trajectory are currently supported.

Usage:

from ksecs.ECS.processors.render_processor import RenderProcessor
class TrajDSL(RenderProcessor):
    def process(self, *args, **kwargs):
        self.gen_traj(**params)

Notes: **params to be specified are in Trajectory.

Albedo map

Ouput format: 4 channel * 8 bits

from ksecs.ECS.processors.pixel_processor import PixelProcessor
class AlbedoDsl(PixelProcessor):
    def process(self, **kwargs):
        self.gen_albedo(distort=0)