Mojo function
scatter_nd_shape
scatter_nd_shape[input_rank: Int, updates_rank: Int, indices_rank: Int, input_type: DType, indices_type: DType, single_thread_blocking_override: Bool](input: NDBuffer[input_type, input_rank, origin], updates: NDBuffer[input_type, updates_rank, origin], indices: NDBuffer[indices_type, indices_rank, origin]) -> Index[input_rank]
Compute the output shape of a scatter_nd
operation, and assert the inputs are compatible.
Parameters:
- input_rank (
Int
): Rank of the input tensor. - updates_rank (
Int
): Rank of the updates tensor. - indices_rank (
Int
): Rank of the indices tensor. - input_type (
DType
): Type of the input tensor. - indices_type (
DType
): Type of the indices tensor. - single_thread_blocking_override (
Bool
): If True, then the operation is run synchronously using a single thread.
Args:
- input (
NDBuffer[input_type, input_rank, origin]
): The input tensor. - updates (
NDBuffer[input_type, updates_rank, origin]
): The input tensor. - indices (
NDBuffer[indices_type, indices_rank, origin]
): The indices tensor.
Returns:
The output shape.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!