tesseract  v4.0.0-17-g361f3264
Open Source OCR Engine
tesseract::LMPainPoints Class Reference

#include <lm_pain_points.h>

Collaboration diagram for tesseract::LMPainPoints:

Public Member Functions

 LMPainPoints (int max, float rat, bool fp, const Dict *d, int deb)
 
 ~LMPainPoints ()
 
bool HasPainPoints (LMPainPointsType pp_type) const
 
LMPainPointsType Deque (MATRIX_COORD *pp, float *priority)
 
void Clear ()
 
void GenerateInitial (WERD_RES *word_res)
 
void GenerateFromPath (float rating_cert_scale, ViterbiStateEntry *vse, WERD_RES *word_res)
 
void GenerateFromAmbigs (const DANGERR &fixpt, ViterbiStateEntry *vse, WERD_RES *word_res)
 
bool GenerateForBlamer (double max_char_wh_ratio, WERD_RES *word_res, int col, int row)
 
bool GeneratePainPoint (int col, int row, LMPainPointsType pp_type, float special_priority, bool ok_to_extend, float max_char_wh_ratio, WERD_RES *word_res)
 
void RemapForSplit (int index)
 

Static Public Member Functions

static const char * PainPointDescription (LMPainPointsType type)
 

Static Public Attributes

static const float kDefaultPainPointPriorityAdjustment = 2.0f
 
static const float kLooseMaxCharWhRatio = 2.5f
 

Private Attributes

PainPointHeap pain_points_heaps_ [LM_PPTYPE_NUM]
 
int max_heap_size_
 
float max_char_wh_ratio_
 
bool fixed_pitch_
 
const Dictdict_
 
int debug_level_
 

Constructor & Destructor Documentation

◆ LMPainPoints()

tesseract::LMPainPoints::LMPainPoints ( int  max,
float  rat,
bool  fp,
const Dict d,
int  deb 
)
inline

◆ ~LMPainPoints()

tesseract::LMPainPoints::~LMPainPoints ( )
inline

Member Function Documentation

◆ Clear()

void tesseract::LMPainPoints::Clear ( )
inline

◆ Deque()

LMPainPointsType tesseract::LMPainPoints::Deque ( MATRIX_COORD pp,
float *  priority 
)

◆ GenerateForBlamer()

bool tesseract::LMPainPoints::GenerateForBlamer ( double  max_char_wh_ratio,
WERD_RES word_res,
int  col,
int  row 
)
inline

◆ GenerateFromAmbigs()

void tesseract::LMPainPoints::GenerateFromAmbigs ( const DANGERR fixpt,
ViterbiStateEntry vse,
WERD_RES word_res 
)

◆ GenerateFromPath()

void tesseract::LMPainPoints::GenerateFromPath ( float  rating_cert_scale,
ViterbiStateEntry vse,
WERD_RES word_res 
)

◆ GenerateInitial()

void tesseract::LMPainPoints::GenerateInitial ( WERD_RES word_res)

◆ GeneratePainPoint()

bool tesseract::LMPainPoints::GeneratePainPoint ( int  col,
int  row,
LMPainPointsType  pp_type,
float  special_priority,
bool  ok_to_extend,
float  max_char_wh_ratio,
WERD_RES word_res 
)

◆ HasPainPoints()

bool tesseract::LMPainPoints::HasPainPoints ( LMPainPointsType  pp_type) const
inline

◆ PainPointDescription()

static const char* tesseract::LMPainPoints::PainPointDescription ( LMPainPointsType  type)
inlinestatic

◆ RemapForSplit()

void tesseract::LMPainPoints::RemapForSplit ( int  index)

Adjusts the pain point coordinates to cope with expansion of the ratings matrix due to a split of the blob with the given index.

Member Data Documentation

◆ debug_level_

int tesseract::LMPainPoints::debug_level_
private

◆ dict_

const Dict* tesseract::LMPainPoints::dict_
private

◆ fixed_pitch_

bool tesseract::LMPainPoints::fixed_pitch_
private

◆ kDefaultPainPointPriorityAdjustment

const float tesseract::LMPainPoints::kDefaultPainPointPriorityAdjustment = 2.0f
static

◆ kLooseMaxCharWhRatio

const float tesseract::LMPainPoints::kLooseMaxCharWhRatio = 2.5f
static

◆ max_char_wh_ratio_

float tesseract::LMPainPoints::max_char_wh_ratio_
private

◆ max_heap_size_

int tesseract::LMPainPoints::max_heap_size_
private

◆ pain_points_heaps_

PainPointHeap tesseract::LMPainPoints::pain_points_heaps_[LM_PPTYPE_NUM]
private

The documentation for this class was generated from the following files: