Skip to content

Commit

Permalink
Merge pull request #4337 from stweil/typos
Browse files Browse the repository at this point in the history
Fix some typos and grammer issues
  • Loading branch information
zdenop authored Oct 28, 2024
2 parents 3633e88 + 3400ce7 commit 9f8e07c
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions src/api/pagerenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ Pta *FitBaselineIntoLinePolygon(Pta *bottom_pts, Pta *baseline_pts,
}

num_pts = ptaGetCount(bottom_pts);
// Create a interpolated polygon with stepsize 1
// Create an interpolated polygon with stepsize 1.
for (int index = 0; index < num_pts - 1; ++index) {
ptaGetIPt(bottom_pts, index, &x0, &y0);
ptaGetIPt(bottom_pts, index + 1, &x1, &y1);
Expand Down Expand Up @@ -636,7 +636,7 @@ bool TessPAGERenderer::AddImageHandler(TessBaseAPI *api) {
"pagecontent.xsd\">\n"
"\t<Metadata");

// If a URL is used to recognize a image add it as <Metadata
// If a URL is used to recognize an image add it as <Metadata
// externalRef="url">
if (std::regex_search(api->GetInputName(),
std::regex("^(https?|ftp|ssh):"))) {
Expand Down
2 changes: 1 addition & 1 deletion src/ccstruct/blobbox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -883,7 +883,7 @@ void vertical_cblob_projection( // project outlines
/**********************************************************************
* vertical_coutline_projection
*
* Compute the vertical projection of a outline from its outlines
* Compute the vertical projection of an outline from its outlines
* and add to the given STATS.
**********************************************************************/

Expand Down
12 changes: 6 additions & 6 deletions src/classify/adaptmatch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -644,12 +644,12 @@ void Classify::StartBackupAdaptiveClassifier() {
* - #EnableLearning
* set to true by this routine
*/
void Classify::SettupPass1() {
void Classify::SetupPass1() {
EnableLearning = classify_enable_learning;

getDict().SettupStopperPass1();
getDict().SetupStopperPass1();

} /* SettupPass1 */
} /* SetupPass1 */

/*---------------------------------------------------------------------------*/
/**
Expand All @@ -660,11 +660,11 @@ void Classify::SettupPass1() {
* Globals:
* - #EnableLearning set to false by this routine
*/
void Classify::SettupPass2() {
void Classify::SetupPass2() {
EnableLearning = false;
getDict().SettupStopperPass2();
getDict().SetupStopperPass2();

} /* SettupPass2 */
} /* SetupPass2 */

/*---------------------------------------------------------------------------*/
/**
Expand Down
4 changes: 2 additions & 2 deletions src/classify/classify.h
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ class TESS_API Classify : public CCStruct {
void DisplayAdaptedChar(TBLOB *blob, INT_CLASS_STRUCT *int_class);
bool AdaptableWord(WERD_RES *word);
void EndAdaptiveClassifier();
void SettupPass1();
void SettupPass2();
void SetupPass1();
void SetupPass2();
void AdaptiveClassifier(TBLOB *Blob, BLOB_CHOICE_LIST *Choices);
void ClassifyAsNoise(ADAPT_RESULTS *Results);
void ResetAdaptiveClassifierInternal();
Expand Down
4 changes: 2 additions & 2 deletions src/dict/dict.h
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,9 @@ class TESS_API Dict {
/// Prints the current choices for this word to stdout.
void DebugWordChoices();
/// Sets up stopper variables in preparation for the first pass.
void SettupStopperPass1();
void SetupStopperPass1();
/// Sets up stopper variables in preparation for the second pass.
void SettupStopperPass2();
void SetupStopperPass2();
/* context.cpp *************************************************************/
/// Check a string to see if it matches a set of lexical rules.
int case_ok(const WERD_CHOICE &word) const;
Expand Down
4 changes: 2 additions & 2 deletions src/dict/stopper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -359,11 +359,11 @@ void Dict::EndDangerousAmbigs() {}

#endif // !defined(DISABLED_LEGACY_ENGINE)

void Dict::SettupStopperPass1() {
void Dict::SetupStopperPass1() {
reject_offset_ = 0.0;
}

void Dict::SettupStopperPass2() {
void Dict::SetupStopperPass2() {
reject_offset_ = stopper_phase2_certainty_rejection_offset;
}

Expand Down
2 changes: 1 addition & 1 deletion src/textord/blkocc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ static void horizontal_cblob_projection( // project outlines
/**
* horizontal_coutline_projection
*
* Compute the horizontal projection of a outline from its outlines
* Compute the horizontal projection of an outline from its outlines
* and add to the given STATS.
*/

Expand Down
2 changes: 1 addition & 1 deletion src/wordrec/language_model.h
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ class LanguageModel {
// (used by ComputeNgramCost()).
float ComputeDenom(BLOB_CHOICE_LIST *curr_list);

// Fills the given consistenty_info based on parent_vse.consistency_info
// Fills the given consistency_info based on parent_vse.consistency_info
// and on the consistency of the given unichar_id with parent_vse.
void FillConsistencyInfo(int curr_col, bool word_end, BLOB_CHOICE *b,
ViterbiStateEntry *parent_vse, WERD_RES *word_res,
Expand Down
4 changes: 2 additions & 2 deletions src/wordrec/tface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ int Wordrec::dict_word(const WERD_CHOICE &word) {
void Wordrec::set_pass1() {
chop_ok_split.set_value(70.0);
language_model_->getParamsModel().SetPass(ParamsModel::PTRAIN_PASS1);
SettupPass1();
SetupPass1();
}

/**
Expand All @@ -108,7 +108,7 @@ void Wordrec::set_pass1() {
void Wordrec::set_pass2() {
chop_ok_split.set_value(pass2_ok_split);
language_model_->getParamsModel().SetPass(ParamsModel::PTRAIN_PASS2);
SettupPass2();
SetupPass2();
}

/**
Expand Down

0 comments on commit 9f8e07c

Please sign in to comment.