16#ifndef THIRD_PARTY_TESSERACT_CLASSIFY_ERRORCOUNTER_H_
17#define THIRD_PARTY_TESSERACT_CLASSIFY_ERRORCOUNTER_H_
125 double *unichar_error,
double *scaled_error, std::string *fonts_report);
159 const std::vector<UnicharRating> &results,
TrainingSample *sample);
163 bool AccumulateJunk(
bool debug,
const std::vector<UnicharRating> &results,
178 double ReportErrors(
int report_level,
CountTypes boosting_mode,
180 double *unichar_error, std::string *fonts_report);
186 static bool ReportString(
bool even_if_empty,
const Counts &counts, std::string &report);
190 static bool ComputeRates(
const Counts &counts,
double rates[
CT_SIZE]);
193 double scaled_error_;
195 double rating_epsilon_;
197 std::vector<Counts> font_counts_;
203 std::vector<int> multi_unichar_counts_;
205 STATS ok_score_hist_;
207 STATS bad_score_hist_;
ICOORD & operator+=(ICOORD &op1, const ICOORD &op2)
static void DebugNewErrors(ShapeClassifier *new_classifier, ShapeClassifier *old_classifier, CountTypes boosting_mode, const FontInfoTable &fontinfo_table, const std::vector< Image > &page_images, SampleIterator *it)
static double ComputeErrorRate(ShapeClassifier *classifier, int report_level, CountTypes boosting_mode, const FontInfoTable &fontinfo_table, const std::vector< Image > &page_images, SampleIterator *it, double *unichar_error, double *scaled_error, std::string *fonts_report)