diff --git a/diff_rast/bin_and_sort_gaussians.py b/diff_rast/bin_and_sort_gaussians.py index 8e1f504f5..44c7d5777 100644 --- a/diff_rast/bin_and_sort_gaussians.py +++ b/diff_rast/bin_and_sort_gaussians.py @@ -24,11 +24,13 @@ class BinAndSortGaussians(Function): tile_bounds (Tuple): tile dimensions as a len 3 tuple (tiles.x , tiles.y, 1). Returns: - isect_ids_unsorted (Tensor): unique IDs for each gaussian in the form (tile | depth id). - gaussian_ids_unsorted (Tensor): Tensor that maps isect_ids back to cum_tiles_hit. Useful for identifying gaussians. - isect_ids_sorted (Tensor): sorted unique IDs for each gaussian in the form (tile | depth id). - gaussian_ids_sorted (Tensor): sorted Tensor that maps isect_ids back to cum_tiles_hit. Useful for identifying gaussians. - tile_bins (Tensor): range of gaussians hit per tile. + A tuple of {Tensor, Tensor, Tensor, Tensor, Tensor}: + + - **isect_ids_unsorted** (Tensor): unique IDs for each gaussian in the form (tile | depth id). + - **gaussian_ids_unsorted** (Tensor): Tensor that maps isect_ids back to cum_tiles_hit. Useful for identifying gaussians. + - **isect_ids_sorted** (Tensor): sorted unique IDs for each gaussian in the form (tile | depth id). + - **gaussian_ids_sorted** (Tensor): sorted Tensor that maps isect_ids back to cum_tiles_hit. Useful for identifying gaussians. + - **tile_bins** (Tensor): range of gaussians hit per tile. """ @staticmethod diff --git a/diff_rast/compute_cumulative_intersects.py b/diff_rast/compute_cumulative_intersects.py index 645e76cb5..1922b0037 100644 --- a/diff_rast/compute_cumulative_intersects.py +++ b/diff_rast/compute_cumulative_intersects.py @@ -17,8 +17,10 @@ class ComputeCumulativeIntersects(Function): num_tiles_hit (Tensor): number of intersected tiles per gaussian. Returns: - num_intersects (int): total number of tile intersections. - cum_tiles_hit (Tensor): a tensor of cumulated intersections (used for sorting). + A tuple of {int, Tensor}: + + - **num_intersects** (int): total number of tile intersections. + - **cum_tiles_hit** (Tensor): a tensor of cumulated intersections (used for sorting). """ @staticmethod diff --git a/diff_rast/cov2d_bounds.py b/diff_rast/cov2d_bounds.py index 9d6250eea..dda93df58 100644 --- a/diff_rast/cov2d_bounds.py +++ b/diff_rast/cov2d_bounds.py @@ -17,8 +17,10 @@ class ComputeCov2dBounds(Function): cov2d (Tensor): input cov2d of size (batch, 3) of upper triangular 2D covariance values Returns: - conic (Tensor): conic parameters for 2D gaussian. - radii (Tensor): radii of 2D gaussian projections. + A tuple of {Tensor, Tensor}: + + - **conic** (Tensor): conic parameters for 2D gaussian. + - **radii** (Tensor): radii of 2D gaussian projections. """ @staticmethod diff --git a/diff_rast/get_tile_bin_edges.py b/diff_rast/get_tile_bin_edges.py index 67f80e2c3..ab7539e2e 100644 --- a/diff_rast/get_tile_bin_edges.py +++ b/diff_rast/get_tile_bin_edges.py @@ -16,12 +16,14 @@ class GetTileBinEdges(Function): Indexing into tile_bins[tile_idx] returns the range (lower,upper) of gaussian IDs that hit tile_idx. - Args: - num_intersects (int): total number of gaussian intersects. - isect_ids_sorted (Tensor): sorted unique IDs for each gaussian in the form (tile | depth id). + Args: + num_intersects (int): total number of gaussian intersects. + isect_ids_sorted (Tensor): sorted unique IDs for each gaussian in the form (tile | depth id). - Returns: - tile_bins (Tensor): range of gaussians IDs hit per tile. + Returns: + A Tensor: + + - **tile_bins** (Tensor): range of gaussians IDs hit per tile. """ @staticmethod diff --git a/diff_rast/map_gaussian_to_intersects.py b/diff_rast/map_gaussian_to_intersects.py index 195ac7bfb..f05bbcde6 100644 --- a/diff_rast/map_gaussian_to_intersects.py +++ b/diff_rast/map_gaussian_to_intersects.py @@ -21,8 +21,10 @@ class MapGaussiansToIntersects(Function): tile_bounds (Tuple): tile dimensions as a len 3 tuple (tiles.x , tiles.y, 1). Returns: - isect_ids (Tensor): unique IDs for each gaussian in the form (tile | depth id). - gaussian_ids (Tensor): Tensor that maps isect_ids back to cum_tiles_hit. Useful for identifying gaussians. + A tuple of {Tensor, Tensor}: + + - **isect_ids** (Tensor): unique IDs for each gaussian in the form (tile | depth id). + - **gaussian_ids** (Tensor): Tensor that maps isect_ids back to cum_tiles_hit. """ @staticmethod diff --git a/diff_rast/project_gaussians.py b/diff_rast/project_gaussians.py index e6470a64f..099a2ce65 100644 --- a/diff_rast/project_gaussians.py +++ b/diff_rast/project_gaussians.py @@ -26,12 +26,14 @@ class ProjectGaussians(Function): tile_bounds (Tuple): tile dimensions as a len 3 tuple (tiles.x , tiles.y, 1). Returns: - xys (Tensor): x,y locations of 2D gaussian projections. - depths (Tensor): z depth of gaussians. - radii (Tensor): radii of 2D gaussian projections. - conics (Tensor): conic parameters for 2D gaussian. - num_tiles_hit (int): number of tiles hit. - cov3d (Tensor): 3D covariances. + A tuple of {Tensor, Tensor, Tensor, Tensor, int, Tensor}: + + - **xys** (Tensor): x,y locations of 2D gaussian projections. + - **depths** (Tensor): z depth of gaussians. + - **radii** (Tensor): radii of 2D gaussian projections. + - **conics** (Tensor): conic parameters for 2D gaussian. + - **num_tiles_hit** (int): number of tiles hit. + - **cov3d** (Tensor): 3D covariances. """ @staticmethod diff --git a/diff_rast/rasterize.py b/diff_rast/rasterize.py index efc3f64ed..39934dbf2 100644 --- a/diff_rast/rasterize.py +++ b/diff_rast/rasterize.py @@ -26,7 +26,9 @@ class RasterizeGaussians(Function): background (Tensor): background color Returns: - out_img (Tensor): the rendered output image. + A Tensor: + + - **out_img** (Tensor): the rendered output image. """ @staticmethod