MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / subtensor

Function subtensor

imperative/python/test/unit/core/test_indexing_op.py:207–210  ·  view source on GitHub ↗
(input, tuple_val)

Source from the content-addressed store, hash-verified

205
206
207def subtensor(input, tuple_val):
208 input, tensors, items = unpack_getitem(input, tuple_val)
209 op = builtin.Subtensor(items)
210 return invoke_op(op, (input, *tensors))
211
212
213def set_subtensor(input, value, tuple_val):

Callers 1

test_subtensorFunction · 0.85

Calls 3

unpack_getitemFunction · 0.85
invoke_opFunction · 0.85
SubtensorMethod · 0.80

Tested by

no test coverage detected