IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /max/get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).

Mojo struct

AdvancedIndexingSetItem

struct AdvancedIndexingSetItem

Registers the advanced_indexing_setitem graph op with the graph compiler.

Implemented traitsโ€‹

AnyType, ImplicitlyDeletable

Methodsโ€‹

executeโ€‹

static def execute[input_rank: Int, index_rank: Int, updates_rank: Int, input_type: DType, index_type: DType, num_index_tensors: Int, //, start_axis: Int, target: StringSlice[ImmStaticOrigin], _trace_name: StringSlice[ImmStaticOrigin]](output_tensor: ManagedTensorSlice[IOSpec[_, _].Output, static_spec=output_tensor.static_spec], input_tensor: ManagedTensorSlice[IOSpec[_, _].FusedInput, static_spec=input_tensor.static_spec], updates: ManagedTensorSlice[IOSpec[_, _].FusedInput, static_spec=updates.static_spec], indices: _FusedInputVariadicTensors[static_specs=indices.static_specs], ctx: DeviceContext)

Implement basic numpy-style advanced indexing with assignment but returns a copy.