Renderer
RandomizeRenderedImage
paz.pipelines.renderer.RandomizeRenderedImage(image_paths, num_occlusions=1, max_radius_scale=0.5)
Performs alpha blending and data-augmentation to an image and it's alpha channel. image_paths: List of strings indicating the paths to the images used for the background. num_occlusions: Int. number of occlusions to be added to the image. max_radius_scale: Float between [0, 1] indicating the maximum radius in scale of the image size.
RenderTwoViews
paz.pipelines.renderer.RenderTwoViews(renderer)
Renders two views along with their transformations.
Arguments
- renderer: A class with a method
renderthat outputs two lists. The first list contains two numpy arrays representing the images e.g.(image_A, image_B)each of shape[H, W, 3]. The other list contains three numpy arrays representing the transformations from the origin to the cameras and the two alpha channels of both images e.g.[matrices, alpha_channel_A, alpha_channel_B].matricesis a numpy array of shape(4, 4 * 4). Each row is a matrix of4 x 4representing the following transformations respectively:world_to_A,world_to_B,A_to_worldandB_to_world. The shape of eachalpha_channelshould be[H, W].