MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ as_tensor()

std::shared_ptr< Kakshya::TensorContainer > MayaFlux::Yantra::PhonemeAnalysis::as_tensor ( const std::vector< float > & values,
uint64_t width,
std::string name )
inlinestaticnodiscardprivate

Definition at line 124 of file PhonemeAnalyzer.hpp.

125 {
126 if (values.empty()) {
127 return nullptr;
128 }
129 auto data = Kakshya::TensorData::from_values<float>(values, { values.size() / width, width }, std::move(name));
130 return data ? std::make_shared<Kakshya::TensorContainer>(std::move(*data)) : nullptr;
131 }
static std::optional< TensorData > from_values(std::span< const T > values, std::vector< uint64_t > shape={}, std::string name={})
Contiguous tensor holding a copy of typed values.
Definition Tensor.hpp:75

References MayaFlux::Kakshya::TensorData::from_values().

Referenced by embedding_tensor(), and posterior_tensor().

Here is the call graph for this function:
Here is the caller graph for this function: