This group is for classes that implement specific ways of reading and writing Tables; see also "Table types and related functions", "Specific Table types", "Specific Table types", and for a description of the Table concept see The Table concept. More...
Functions | |
SequentialTableReader (const std::string &rspecifier) | |
bool | Open (const std::string &rspecifier) |
bool | Close () |
bool | IsOpen () const |
std::string | Key () |
void | FreeCurrent () |
T & | Value () |
void | Next () |
bool | Done () |
~SequentialTableReader () | |
TableWriter (const std::string &wspecifier) | |
bool | IsOpen () const |
bool | Open (const std::string &wspecifier) |
void | Write (const std::string &key, const T &value) const |
void | Flush () |
bool | Close () |
~TableWriter () | |
RandomAccessTableReader (const std::string &rspecifier) | |
bool | Open (const std::string &rspecifier) |
bool | HasKey (const std::string &key) |
const T & | Value (const std::string &key) |
bool | Close () |
~RandomAccessTableReader () | |
void | CheckImpl () const |
void | CheckImpl () const |
void | CheckImpl () const |
RandomAccessTableReaderMapped (const std::string &table_rxfilename, const std::string &utt2spk_rxfilename) | |
Note: "utt2spk_rxfilename" will in the normal case be an rxfilename for an utterance to speaker map, but this code is general; it accepts a generic map. More... | |
bool | Open (const std::string &table_rxfilename, const std::string &utt2spk_rxfilename) |
Note: when calling Open, utt2spk_rxfilename may be empty. More... | |
bool | HasKey (const std::string &key) |
const T & | Value (const std::string &key) |
This group is for classes that implement specific ways of reading and writing Tables; see also "Table types and related functions", "Specific Table types", "Specific Table types", and for a description of the Table concept see The Table concept.
|
private |
Definition at line 2590 of file kaldi-table-inl.h.
|
private |
Definition at line 2582 of file kaldi-table-inl.h.
References KALDI_ERR.
Referenced by SequentialTableReader< Holder >::Close(), SequentialTableReader< Holder >::Done(), SequentialTableReader< Holder >::FreeCurrent(), SequentialTableReader< Holder >::Key(), SequentialTableReader< Holder >::Next(), and SequentialTableReader< Holder >::Value().
|
private |
Definition at line 2598 of file kaldi-table-inl.h.
References KALDI_ERR.
Referenced by TableWriter< Holder >::Close(), TableWriter< Holder >::Flush(), and TableWriter< Holder >::Write().
bool Close | ( | ) |
Definition at line 2567 of file kaldi-table-inl.h.
bool Close | ( | ) |
Definition at line 901 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by main(), SequentialTableReader< Holder >::Open(), TableWriterArchiveImpl< Holder >::Open(), TableWriterBothImpl< Holder >::Open(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), kaldi::UnitTestTableSequentialInt32VectorVectorBoth(), TableWriterArchiveImpl< Holder >::~TableWriterArchiveImpl(), and TableWriterBothImpl< Holder >::~TableWriterBothImpl().
bool Close | ( | ) |
Definition at line 1527 of file kaldi-table-inl.h.
References TableWriter< Holder >::CheckImpl(), and TableWriter< Holder >::impl_.
Referenced by TableWriter< Holder >::Open(), RandomAccessTableReaderArchiveImplBase< Holder >::Open(), kaldi::TestCompactLatticeTable(), kaldi::TestCompactLatticeTableCross(), kaldi::TestLatticeTable(), kaldi::TestLatticeTableCross(), kaldi::UnitTestTableRandomBothDouble(), kaldi::UnitTestTableRandomBothDoubleMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), kaldi::UnitTestTableSequentialInt32VectorVectorBoth(), RandomAccessTableReaderDSortedArchiveImpl< Holder >::~RandomAccessTableReaderDSortedArchiveImpl(), RandomAccessTableReaderSortedArchiveImpl< Holder >::~RandomAccessTableReaderSortedArchiveImpl(), RandomAccessTableReaderUnsortedArchiveImpl< Holder >::~RandomAccessTableReaderUnsortedArchiveImpl(), and TableWriter< Holder >::~TableWriter().
|
inline |
Definition at line 948 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by ComputeLogPosteriors(), ComputeScores(), CopyExcludedFeats(), CopyIncludedFeats(), kaldi::CopySubsetLattices(), kaldi::nnet2::DoBackpropParallel(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), kaldi::GetFeatureMeanAndVariance(), main(), kaldi::nnet2::NnetDiscriminativeUpdateParallel(), kaldi::ReadData(), NnetExampleBackgroundReader::ReadExamples(), kaldi::RunPerSpeaker(), CRnnLM::setUnkPenalty(), kaldi::TypeOneUsage(), kaldi::TypeOneUsageAverage(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), and kaldi::UnitTestTableSequentialInt32VectorVectorBoth().
void Flush | ( | ) |
Definition at line 1521 of file kaldi-table-inl.h.
References TableWriter< Holder >::CheckImpl(), and TableWriter< Holder >::impl_.
void FreeCurrent | ( | ) |
Definition at line 926 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by main(), CRnnLM::setUnkPenalty(), kaldi::TypeOneUsage(), and kaldi::TypeOneUsageAverage().
bool HasKey | ( | const std::string & | key | ) |
Definition at line 2551 of file kaldi-table-inl.h.
Referenced by kaldi::AccCmvnStatsWrapper(), kaldi::AccumulateForUtterance(), ComputeScores(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), main(), kaldi::ProcessUtterance(), kaldi::ReadData(), kaldi::RunPerSpeaker(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableRandomBothDouble(), and kaldi::UnitTestTableRandomBothDoubleMatrix().
bool HasKey | ( | const std::string & | key | ) |
Definition at line 2633 of file kaldi-table-inl.h.
References KALDI_ERR, kaldi::PrintableRxfilename(), RandomAccessTableReaderMapped< Holder >::reader_, RandomAccessTableReaderMapped< Holder >::token_reader_, and RandomAccessTableReaderMapped< Holder >::utt2spk_rxfilename_.
Referenced by main(), and kaldi::ProcessUtterance().
bool IsOpen | ( | ) | const |
Definition at line 911 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::impl_.
Referenced by TableWriterArchiveImpl< Holder >::Close(), TableWriterScriptImpl< Holder >::Close(), TableWriterBothImpl< Holder >::Close(), SequentialTableReader< Holder >::Open(), TableWriterScriptImpl< Holder >::Write(), TableWriterArchiveImpl< Holder >::~TableWriterArchiveImpl(), and TableWriterBothImpl< Holder >::~TableWriterBothImpl().
bool IsOpen | ( | ) | const |
Definition at line 1474 of file kaldi-table-inl.h.
References TableWriter< Holder >::impl_.
Referenced by kaldi::AlignUtteranceWrapper(), RandomAccessTableReaderScriptImpl< Holder >::Close(), RandomAccessTableReaderArchiveImplBase< Holder >::CloseInternal(), kaldi::DecodeUtterance(), DecodeUtterance(), kaldi::DecodeUtteranceLatticeFaster(), kaldi::DecodeUtteranceLatticeIncremental(), kaldi::DecodeUtteranceLatticeSimple(), main(), TableWriter< Holder >::Open(), DecodeUtteranceLatticeFasterClass::~DecodeUtteranceLatticeFasterClass(), RandomAccessTableReaderDSortedArchiveImpl< Holder >::~RandomAccessTableReaderDSortedArchiveImpl(), RandomAccessTableReaderSortedArchiveImpl< Holder >::~RandomAccessTableReaderSortedArchiveImpl(), RandomAccessTableReaderUnsortedArchiveImpl< Holder >::~RandomAccessTableReaderUnsortedArchiveImpl(), and TableWriter< Holder >::~TableWriter().
|
inline |
Definition at line 918 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by ComputeLogPosteriors(), ComputeScores(), CopyExcludedFeats(), CopyIncludedFeats(), kaldi::CopySubsetLattices(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), main(), kaldi::ReadData(), kaldi::RunPerSpeaker(), CRnnLM::setUnkPenalty(), kaldi::TypeOneUsage(), kaldi::TypeOneUsageAverage(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), and kaldi::UnitTestTableSequentialInt32VectorVectorBoth().
void Next | ( | ) |
Definition at line 942 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by ComputeLogPosteriors(), ComputeScores(), CopyExcludedFeats(), CopyIncludedFeats(), kaldi::CopySubsetLattices(), kaldi::nnet2::DoBackpropParallel(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), kaldi::GetFeatureMeanAndVariance(), main(), kaldi::nnet2::NnetDiscriminativeUpdateParallel(), kaldi::ReadData(), NnetExampleBackgroundReader::ReadExamples(), kaldi::RunPerSpeaker(), CRnnLM::setUnkPenalty(), kaldi::TypeOneUsage(), kaldi::TypeOneUsageAverage(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), and kaldi::UnitTestTableSequentialInt32VectorVectorBoth().
bool Open | ( | const std::string & | rspecifier | ) |
Definition at line 2517 of file kaldi-table-inl.h.
Referenced by main().
bool Open | ( | const std::string & | rspecifier | ) |
Definition at line 864 of file kaldi-table-inl.h.
References RspecifierOptions::background, kaldi::ClassifyRspecifier(), SequentialTableReader< Holder >::Close(), SequentialTableReader< Holder >::impl_, SequentialTableReader< Holder >::IsOpen(), KALDI_ERR, KALDI_WARN, kaldi::kArchiveRspecifier, kaldi::kNoRspecifier, and kaldi::kScriptRspecifier.
Referenced by main(), and SequentialTableReader< Holder >::SequentialTableReader().
bool Open | ( | const std::string & | wspecifier | ) |
Definition at line 1480 of file kaldi-table-inl.h.
References kaldi::ClassifyWspecifier(), TableWriter< Holder >::Close(), TableWriter< Holder >::impl_, TableWriter< Holder >::IsOpen(), KALDI_ASSERT, KALDI_ERR, KALDI_WARN, kaldi::kArchiveWspecifier, kaldi::kBothWspecifier, kaldi::kNoWspecifier, and kaldi::kScriptWspecifier.
Referenced by main(), and TableWriter< Holder >::TableWriter().
bool Open | ( | const std::string & | table_rxfilename, |
const std::string & | utt2spk_rxfilename | ||
) |
Note: when calling Open, utt2spk_rxfilename may be empty.
Definition at line 2614 of file kaldi-table-inl.h.
References KALDI_ASSERT, RandomAccessTableReaderMapped< Holder >::reader_, and RandomAccessTableReaderMapped< Holder >::token_reader_.
Referenced by main().
|
explicit |
Definition at line 2508 of file kaldi-table-inl.h.
RandomAccessTableReaderMapped | ( | const std::string & | table_rxfilename, |
const std::string & | utt2spk_rxfilename | ||
) |
Note: "utt2spk_rxfilename" will in the normal case be an rxfilename for an utterance to speaker map, but this code is general; it accepts a generic map.
Definition at line 2606 of file kaldi-table-inl.h.
|
explicit |
Definition at line 857 of file kaldi-table-inl.h.
References KALDI_ERR, and SequentialTableReader< Holder >::Open().
|
explicit |
Definition at line 1467 of file kaldi-table-inl.h.
References KALDI_ERR, and TableWriter< Holder >::Open().
const RandomAccessTableReader< Holder >::T & Value | ( | const std::string & | key | ) |
Definition at line 2561 of file kaldi-table-inl.h.
Referenced by kaldi::AccCmvnStatsWrapper(), kaldi::AccumulateForUtterance(), ComputeScores(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), main(), kaldi::ProcessUtterance(), kaldi::ReadData(), kaldi::RunPerSpeaker(), kaldi::TestCompactLatticeTable(), kaldi::TestCompactLatticeTableCross(), kaldi::TestLatticeTable(), kaldi::TestLatticeTableCross(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableRandomBothDouble(), and kaldi::UnitTestTableRandomBothDoubleMatrix().
SequentialTableReader< Holder >::T & Value | ( | ) |
Definition at line 934 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::CheckImpl(), and SequentialTableReader< Holder >::impl_.
Referenced by ComputeLogPosteriors(), ComputeScores(), CopyExcludedFeats(), CopyIncludedFeats(), kaldi::CopySubsetLattices(), kaldi::nnet2::DoBackpropParallel(), kaldi::GetEditsDualHyp(), kaldi::GetEditsSingleHyp(), kaldi::GetFeatureMeanAndVariance(), main(), kaldi::nnet2::NnetDiscriminativeUpdateParallel(), kaldi::ReadData(), NnetExampleBackgroundReader::ReadExamples(), kaldi::RunPerSpeaker(), CRnnLM::setUnkPenalty(), kaldi::TypeOneUsage(), kaldi::TypeOneUsageAverage(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), and kaldi::UnitTestTableSequentialInt32VectorVectorBoth().
const Holder::T & Value | ( | const std::string & | key | ) |
Definition at line 2650 of file kaldi-table-inl.h.
References KALDI_ERR, kaldi::PrintableRxfilename(), RandomAccessTableReaderMapped< Holder >::reader_, RandomAccessTableReaderMapped< Holder >::token_reader_, and RandomAccessTableReaderMapped< Holder >::utt2spk_rxfilename_.
Referenced by main(), and kaldi::ProcessUtterance().
|
inline |
Definition at line 1511 of file kaldi-table-inl.h.
References TableWriter< Holder >::CheckImpl(), TableWriter< Holder >::impl_, and KALDI_ERR.
Referenced by kaldi::AlignUtteranceWrapper(), ComputeLogPosteriors(), CopyExcludedFeats(), CopyIncludedFeats(), kaldi::CopySubsetLattices(), kaldi::DecodeUtterance(), DecodeUtterance(), kaldi::DecodeUtteranceLatticeFaster(), kaldi::DecodeUtteranceLatticeIncremental(), kaldi::DecodeUtteranceLatticeSimple(), kaldi::HandleOutput(), main(), OutputDetailedStatistics(), kaldi::nnet2::ProcessFile(), kaldi::nnet3::ProcessFile(), kaldi::RunPerSpeaker(), kaldi::TestCompactLatticeTable(), kaldi::TestCompactLatticeTableCross(), kaldi::TestLatticeTable(), kaldi::TestLatticeTableCross(), kaldi::TypeOneUsage(), kaldi::TypeOneUsageAverage(), kaldi::UnitTestRangesMatrix(), kaldi::UnitTestTableRandomBothDouble(), kaldi::UnitTestTableRandomBothDoubleMatrix(), kaldi::UnitTestTableSequentialBaseFloatVectorBoth(), kaldi::UnitTestTableSequentialBool(), kaldi::UnitTestTableSequentialDouble(), kaldi::UnitTestTableSequentialDoubleBoth(), kaldi::UnitTestTableSequentialDoubleMatrixBoth(), kaldi::UnitTestTableSequentialInt32(), kaldi::UnitTestTableSequentialInt32PairVectorBoth(), kaldi::UnitTestTableSequentialInt32Script(), kaldi::UnitTestTableSequentialInt32VectorBoth(), kaldi::UnitTestTableSequentialInt32VectorVectorBoth(), DiscriminativeExampleMerger::WriteMinibatch(), ChainExampleMerger::WriteMinibatch(), ExampleMerger::WriteMinibatch(), DecodeUtteranceLatticeFasterClass::~DecodeUtteranceLatticeFasterClass(), DeterminizeLatticeTask::~DeterminizeLatticeTask(), and IvectorExtractTask::~IvectorExtractTask().
Definition at line 2576 of file kaldi-table-inl.h.
Definition at line 955 of file kaldi-table-inl.h.
References SequentialTableReader< Holder >::impl_.
~TableWriter | ( | ) |
Definition at line 1537 of file kaldi-table-inl.h.
References TableWriter< Holder >::Close(), TableWriter< Holder >::IsOpen(), and KALDI_ERR.