get_traced_pixels#

silmaril.imaging.get_traced_pixels(source_grid, traced_pixel_corners, nonempty_pixels=None)#

Returns a list of polygons on the source plane corresponding to pixels on the image plane. Each polygon is represented as an array of shape (4,2) where each row is a vertex of the polygon.

Parameters:
  • source_grid (Grid) – grid of source plane coordinates

  • traced_corners_grid (numpy.ndarray) – grid of source plane coordinates of the corners of each pixel on the image plane

Returns:

polygons – list of polygons on the source plane as an array of shape (n,4,2)

Return type:

numpy.ndarray