MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / Next

Method Next

external/sentencepiece/src/trainer_interface.cc:180–195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

178}
179
180void MultiFileSentenceIterator::Next() {
181 TryRead();
182
183 if (!read_done_ && file_index_ < files_.size()) {
184 const auto &filename = files_[file_index_++];
185 fp_ = filesystem::NewReadableFile(filename);
186 LOG(INFO) << "Loading corpus: " << filename;
187 if (fp_->status() != util::OkStatus()) {
188 file_index_ = files_.size();
189 read_done_ = false;
190 return;
191 }
192
193 TryRead();
194 }
195}
196
197void MultiFileSentenceIterator::TryRead() {
198 read_done_ = fp_ && fp_->ReadLine(&value_);

Callers 2

LoadSentencesMethod · 0.45
TESTFunction · 0.45

Calls 4

NewReadableFileFunction · 0.85
OkStatusFunction · 0.85
sizeMethod · 0.45
statusMethod · 0.45

Tested by 1

TESTFunction · 0.36