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

◆ pieces_of()

template<ComputeData InputType = std::vector<Kakshya::DataVariant>, ComputeData OutputType = Kakshya::CompositeArray>
std::vector< Piece > MayaFlux::Yantra::PhonemeExtractor< InputType, OutputType >::pieces_of ( const PhonemeExtraction & record,
const std::vector< size_t > & rows )
inlinestaticprivate

Definition at line 305 of file PhonemeExtractor.hpp.

306 {
307 const bool gated = gate_applies(record.config);
309 for (const size_t row : rows) {
310 const auto& event = record.events[row];
311 if (event.end <= event.start) {
312 continue;
313 }
314 if (!gated) {
315 pieces.push_back({ event.start, event.end, row });
316 continue;
317 }
318 for (const auto& [start, end] : Kinesis::Discrete::intersect_intervals({ { event.start, event.end } }, record.voiced)) {
319 pieces.push_back({ start, end, row });
320 }
321 }
322 return pieces;
323 }
const Config & config() const
The stored config struct of type Config, or its defaults when none was set.
static bool gate_applies(const PhonemeExtractorConfig &cfg)
The phonemes of a whole mono 16 kHz recording, with the pauses between speech taken out.

Referenced by MayaFlux::Yantra::PhonemeExtractor< std::vector< Kakshya::DataVariant >, Kakshya::CompositeArray >::build_output().

Here is the caller graph for this function: