MCPcopy Create free account
hub / github.com/alibaba/MNN / _StridedSliceWrite

Function _StridedSliceWrite

express/NeuralNetWorkOp.cpp:594–608  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

592}
593
594VARP _StridedSliceWrite(VARP input, VARP begin, VARP end, VARP strided, VARP write, int32_t beginMask,
595 int32_t endMask, int32_t ellipsisMask, int32_t newAxisMask, int32_t shrinkAxisMask) {
596 std::unique_ptr<OpT> op(new OpT);
597 op->type = OpType_StridedSlice;
598 op->main.type = OpParameter_StridedSliceParam;
599 op->main.value = new StridedSliceParamT;
600
601 op->main.AsStridedSliceParam()->T = DataType_DT_FLOAT;
602 op->main.AsStridedSliceParam()->beginMask = beginMask;
603 op->main.AsStridedSliceParam()->endMask = endMask;
604 op->main.AsStridedSliceParam()->ellipsisMask = ellipsisMask;
605 op->main.AsStridedSliceParam()->newAxisMask = newAxisMask;
606 op->main.AsStridedSliceParam()->shrinkAxisMask = shrinkAxisMask;
607 return (Variable::create(Expr::create(op.get(), {input, begin, end, strided, write})));
608}
609/*Transposes x.
610Args:
611x: A variable.

Callers 3

onGradMethod · 0.85
runMethod · 0.85
PyMNNVar_ass_subscriptFunction · 0.85

Calls 3

AsStridedSliceParamMethod · 0.80
createFunction · 0.50
getMethod · 0.45

Tested by 1

runMethod · 0.68