tesseract 4.1.1
|
#include <equationdetect.h>
Public Types | |
enum | IndentType { NO_INDENT , LEFT_INDENT , RIGHT_INDENT , BOTH_INDENT , INDENT_TYPE_COUNT } |
Public Member Functions | |
EquationDetect (const char *equ_datapath, const char *equ_language) | |
~EquationDetect () override | |
void | SetLangTesseract (Tesseract *lang_tesseract) |
int | LabelSpecialText (TO_BLOCK *to_block) override |
int | FindEquationParts (ColPartitionGrid *part_grid, ColPartitionSet **best_columns) override |
void | SetResolution (const int resolution) |
![]() | |
EquationDetectBase ()=default | |
virtual | ~EquationDetectBase () |
virtual int | LabelSpecialText (TO_BLOCK *to_block)=0 |
virtual int | FindEquationParts (ColPartitionGrid *part_grid, ColPartitionSet **best_columns)=0 |
Protected Member Functions | |
void | IdentifySpecialText (BLOBNBOX *blob, const int height_th) |
BlobSpecialTextType | EstimateTypeForUnichar (const UNICHARSET &unicharset, const UNICHAR_ID id) const |
void | IdentifySpecialText () |
void | IdentifyBlobsToSkip (ColPartition *part) |
void | MergePartsByLocation () |
void | SearchByOverlap (ColPartition *seed, GenericVector< ColPartition * > *parts_overlap) |
void | InsertPartAfterAbsorb (ColPartition *part) |
void | IdentifySeedParts () |
bool | CheckSeedBlobsCount (ColPartition *part) |
float | ComputeForegroundDensity (const TBOX &tbox) |
bool | CheckForSeed2 (const GenericVector< int > &indented_texts_left, const float foreground_density_th, ColPartition *part) |
int | CountAlignment (const GenericVector< int > &sorted_vec, const int val) const |
bool | CheckSeedFgDensity (const float density_th, ColPartition *part) |
void | SplitCPHorLite (ColPartition *part, GenericVector< TBOX > *splitted_boxes) |
void | SplitCPHor (ColPartition *part, GenericVector< ColPartition * > *parts_splitted) |
bool | CheckSeedDensity (const float math_density_high, const float math_density_low, const ColPartition *part) const |
IndentType | IsIndented (ColPartition *part) |
void | IdentifyInlineParts () |
void | ComputeCPsSuperBBox () |
void | IdentifyInlinePartsHorizontal () |
int | EstimateTextPartLineSpacing () |
void | IdentifyInlinePartsVertical (const bool top_to_bottom, const int textPartsLineSpacing) |
bool | IsInline (const bool search_bottom, const int textPartsLineSpacing, ColPartition *part) |
bool | ExpandSeed (ColPartition *seed) |
void | ExpandSeedHorizontal (const bool search_left, ColPartition *seed, GenericVector< ColPartition * > *parts_to_merge) |
void | ExpandSeedVertical (const bool search_bottom, ColPartition *seed, GenericVector< ColPartition * > *parts_to_merge) |
bool | IsNearSmallNeighbor (const TBOX &seed_box, const TBOX &part_box) const |
bool | CheckSeedNeighborDensity (const ColPartition *part) const |
void | ProcessMathBlockSatelliteParts () |
bool | IsMathBlockSatellite (ColPartition *part, GenericVector< ColPartition * > *math_blocks) |
ColPartition * | SearchNNVertical (const bool search_bottom, const ColPartition *part) |
bool | IsNearMathNeighbor (const int y_gap, const ColPartition *neighbor) const |
void | GetOutputTiffName (const char *name, STRING *image_name) const |
void | PaintColParts (const STRING &outfile) const |
void | PaintSpecialTexts (const STRING &outfile) const |
void | PrintSpecialBlobsDensity (const ColPartition *part) const |
Protected Attributes | |
Tesseract | equ_tesseract_ |
Tesseract * | lang_tesseract_ |
ColPartitionGrid * | part_grid_ = nullptr |
ColPartitionSet ** | best_columns_ = nullptr |
TBOX * | cps_super_bbox_ |
GenericVector< ColPartition * > | cp_seeds_ |
int | resolution_ |
int | page_count_ |
Additional Inherited Members | |
![]() | |
static void | RenderSpecialText (Pix *pix, BLOBNBOX *blob) |
Definition at line 38 of file equationdetect.h.
Enumerator | |
---|---|
NO_INDENT | |
LEFT_INDENT | |
RIGHT_INDENT | |
BOTH_INDENT | |
INDENT_TYPE_COUNT |
Definition at line 44 of file equationdetect.h.
tesseract::EquationDetect::EquationDetect | ( | const char * | equ_datapath, |
const char * | equ_language | ||
) |
Definition at line 102 of file equationdetect.cpp.
|
override |
Definition at line 121 of file equationdetect.cpp.
|
protected |
Definition at line 737 of file equationdetect.cpp.
|
protected |
Definition at line 983 of file equationdetect.cpp.
|
protected |
Definition at line 1001 of file equationdetect.cpp.
|
protected |
Definition at line 625 of file equationdetect.cpp.
|
protected |
Definition at line 1292 of file equationdetect.cpp.
|
protected |
Definition at line 791 of file equationdetect.cpp.
|
protected |
Definition at line 611 of file equationdetect.cpp.
|
protected |
Definition at line 759 of file equationdetect.cpp.
|
protected |
Definition at line 867 of file equationdetect.cpp.
|
protected |
Definition at line 224 of file equationdetect.cpp.
|
protected |
Definition at line 1084 of file equationdetect.cpp.
|
protected |
Definition at line 1127 of file equationdetect.cpp.
|
protected |
Definition at line 1183 of file equationdetect.cpp.
|
overridevirtual |
Implements tesseract::EquationDetectBase.
Definition at line 358 of file equationdetect.cpp.
|
protected |
Definition at line 1456 of file equationdetect.cpp.
|
protected |
Definition at line 310 of file equationdetect.cpp.
|
protected |
Definition at line 783 of file equationdetect.cpp.
|
protected |
Definition at line 802 of file equationdetect.cpp.
|
protected |
Definition at line 907 of file equationdetect.cpp.
|
protected |
Definition at line 539 of file equationdetect.cpp.
|
protected |
Definition at line 258 of file equationdetect.cpp.
|
protected |
Definition at line 151 of file equationdetect.cpp.
|
protected |
Definition at line 512 of file equationdetect.cpp.
|
protected |
Definition at line 1020 of file equationdetect.cpp.
|
protected |
Definition at line 936 of file equationdetect.cpp.
|
protected |
Definition at line 1358 of file equationdetect.cpp.
|
protected |
Definition at line 1447 of file equationdetect.cpp.
|
protected |
Definition at line 1270 of file equationdetect.cpp.
|
overridevirtual |
Implements tesseract::EquationDetectBase.
Definition at line 131 of file equationdetect.cpp.
|
protected |
Definition at line 424 of file equationdetect.cpp.
|
protected |
Definition at line 1481 of file equationdetect.cpp.
|
protected |
Definition at line 1464 of file equationdetect.cpp.
|
protected |
Definition at line 1504 of file equationdetect.cpp.
|
protected |
Definition at line 1309 of file equationdetect.cpp.
|
protected |
Definition at line 463 of file equationdetect.cpp.
|
protected |
Definition at line 1412 of file equationdetect.cpp.
void tesseract::EquationDetect::SetLangTesseract | ( | Tesseract * | lang_tesseract | ) |
Definition at line 123 of file equationdetect.cpp.
void tesseract::EquationDetect::SetResolution | ( | const int | resolution | ) |
Definition at line 127 of file equationdetect.cpp.
|
protected |
Definition at line 647 of file equationdetect.cpp.
|
protected |
Definition at line 697 of file equationdetect.cpp.
|
protected |
Definition at line 256 of file equationdetect.h.
|
protected |
Definition at line 262 of file equationdetect.h.
|
protected |
Definition at line 259 of file equationdetect.h.
|
protected |
Definition at line 243 of file equationdetect.h.
|
protected |
Definition at line 247 of file equationdetect.h.
|
protected |
Definition at line 268 of file equationdetect.h.
|
protected |
Definition at line 251 of file equationdetect.h.
|
protected |
Definition at line 265 of file equationdetect.h.