MCPcopy Create free account
hub / github.com/RenderKit/oidn / DeviceTensor

Method DeviceTensor

core/tensor.cpp:159–164  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

157 // -----------------------------------------------------------------------------------------------
158
159 DeviceTensor::DeviceTensor(Engine* engine, const TensorDesc& desc, Storage storage)
160 : Tensor(desc)
161 {
162 buffer = engine->newBuffer(getByteSize(), storage);
163 ptr = buffer->getPtr();
164 }
165
166 DeviceTensor::DeviceTensor(const Ref<Buffer>& buffer, const TensorDesc& desc, size_t byteOffset)
167 : Tensor(buffer, desc, byteOffset)

Callers

nothing calls this directly

Calls 5

ExceptionFunction · 0.85
getByteSizeFunction · 0.70
newBufferMethod · 0.45
getPtrMethod · 0.45
getByteSizeMethod · 0.45

Tested by

no test coverage detected