For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).
Mojo function
roi_align_gpu
def roi_align_gpu[dtype: DType, aligned: Bool, mode: StaticString = "AVG"](output: TileTensor[dtype, Engine=output.Engine, address_space=output.address_space, linear_idx_type=output.linear_idx_type], input: TileTensor[dtype, Engine=input.Engine, address_space=input.address_space, linear_idx_type=input.linear_idx_type], rois: TileTensor[dtype, Engine=rois.Engine, address_space=rois.address_space, linear_idx_type=rois.linear_idx_type], output_height: Int, output_width: Int, in_spatial_scale: Scalar, in_sampling_ratio: Scalar, ctx: DeviceContext)
GPU RoI Align for NHWC input.
Args:
- output (
TileTensor[dtype, Engine=output.Engine, address_space=output.address_space, linear_idx_type=output.linear_idx_type]): Pre-allocated output tensor[M, pooled_h, pooled_w, C]. - input (
TileTensor[dtype, Engine=input.Engine, address_space=input.address_space, linear_idx_type=input.linear_idx_type]): Batched images[N, H, W, C]. - rois (
TileTensor[dtype, Engine=rois.Engine, address_space=rois.address_space, linear_idx_type=rois.linear_idx_type]): ROI box coordinates[M, 5]. - output_height (
Int): Pooled output height. - output_width (
Int): Pooled output width. - in_spatial_scale (
Scalar): Scale factor remapping ROI coordinates to input. - in_sampling_ratio (
Scalar): Sampling points per pooled bin. - ctx (
DeviceContext): Device context for the participating GPU.