MCPcopy Create free account
hub / github.com/catboost/catboost / CountLines

Function CountLines

catboost/private/libs/data_util/line_data_reader.cpp:18–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16 }
17
18 int CountLines(const TString& poolFile) {
19 CB_ENSURE(NFs::Exists(TString(poolFile)), "pool file '" << TString(poolFile) << "' is not found");
20 TIFStream reader(poolFile.c_str());
21 size_t count = 0;
22 TString buffer;
23 while (reader.ReadLine(buffer)) {
24 ++count;
25 }
26 return count;
27 }
28
29
30 TBlocksSubsetLineDataReader::TBlocksSubsetLineDataReader(THolder<ILineDataReader>&& lineDataReader, TVector<TIndexRange<ui64>>&& subsetBlocks)

Callers 1

GetDataLineCountMethod · 0.85

Calls 2

c_strMethod · 0.45
ReadLineMethod · 0.45

Tested by

no test coverage detected