Mojo function
arg_nonzero_shape
arg_nonzero_shape[dtype: DType, single_thread_blocking_override: Bool](input_buffer: TileTensor[dtype, LayoutType, origin, address_space=address_space, linear_idx_type=linear_idx_type, element_shape_types=element_shape_types]) -> IndexList[2]
Return [NumNonZeros, InputRank] where NumNonZeros are the number of non-zero elements in the input.
Parameters:
Args:
- โinput_buffer (
TileTensor): The tensor to count the non-zeros in.
Returns:
IndexList: Shape of the arg_nonzero kernel for this input [NumNonZeros, InputRank].
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!