MCPcopy Create free account
hub / github.com/FastFlowLM/FastFlowLM / assign

Method assign

src/include/tensor_2d.hpp:35–41  ·  view source on GitHub ↗

\brief assign the buffer to the tensor_2d \param buf the buffer to assign

Source from the content-addressed store, hash-verified

33 /// \brief assign the buffer to the tensor_2d
34 /// \param buf the buffer to assign
35 void assign(buffer<T> &buf){
36 this->buf = &buf;
37 temp.resize(buf.size() / D);
38 for (uint32_t i = 0; i < temp.size(); i++){
39 temp[i] = buffer<T>(buf.data() + i * D, D);
40 }
41 }
42
43 /// \brief clear the tensor_2d
44 void clear(){

Callers 4

sampler_topk_applyMethod · 0.80
clip_audio_lengthMethod · 0.80
bytes_to_hex_stringFunction · 0.80
hash256_hex_stringFunction · 0.80

Calls 3

resizeMethod · 0.45
sizeMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected