HostTensor

class HostTensor : public ngraph::runtime::Tensor

Public Functions

void write(const void *p, size_t n)

Write bytes directly into the tensor.

Parameters
  • p: Pointer to source of data
  • n: Number of bytes to write, must be integral number of elements.

void read(void *p, size_t n) const

Read bytes directly from the tensor.

Parameters
  • p: Pointer to destination for data
  • n: Number of bytes to read, must be integral number of elements.