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

Function _createTensor

source/utils/InitNet.cpp:114–119  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

112}
113
114static void _createTensor(std::shared_ptr<Tensor>& dst, int index) {
115 if (dst.get() == nullptr) {
116 dst.reset(new Tensor);
117 TensorUtils::getDescribe(dst.get())->index = index;
118 }
119}
120bool initTensors(std::vector<std::shared_ptr<Tensor>>& tensors, const Net* net, const int* oplists, size_t opListSize) {
121 bool valid = true;
122 auto describes = net->extraTensorDescribe();

Callers 1

initTensorsFunction · 0.85

Calls 2

getMethod · 0.45
resetMethod · 0.45

Tested by

no test coverage detected