tesseract-doxygen/wordrec/bestfirst.cpp File Reference

#include <assert.h>
#include "bestfirst.h"
#include "associate.h"
#include "blobs.h"
#include <math.h>
#include "states.h"
#include "oldheap.h"
#include "ratngs.h"
#include "seam.h"
#include "stopper.h"
#include "tessclas.h"
#include "baseline.h"
#include "bitvec.h"
#include "callback.h"
#include "dict.h"
#include "freelist.h"
#include "globals.h"
#include "bestfirst.h"
#include "permute.h"
#include "matrix.h"
#include "host.h"
#include "callcpp.h"
#include "structures.h"
#include "tordvars.h"
#include "unicharset.h"
#include "classify.h"
#include <stdio.h>

Namespaces

namespace  tesseract

Functions

void call_caller ()
chunks_width

Return the width of a chunk which is a composed of several blobs blobs[start_blob..last_blob] inclusively, whose individual widths and gaps are record in width_record in the form width_record->num_char = n width_record->widths[2*n-1] = w0,g0,w1,g1..w(n-1),g(n-1)

int chunks_width (WIDTH_RECORD *width_record, int start_blob, int last_blob)
chunks_gap

Return the width of between the specified chunk and next.

int chunks_gap (WIDTH_RECORD *width_record, int last_chunk)
void delete_search (SEARCH_RECORD *the_search)
new_search

Create and initialize a new search record.

SEARCH_RECORDnew_search (CHUNKS_RECORD *chunks_record, int num_joints, WERD_CHOICE *best_choice, WERD_CHOICE *raw_choice, STATE *state)
pop_queue

Get this state from the priority queue. It should be the state that has the greatest urgency to be evaluated.

STATEpop_queue (HEAP *queue)
push_queue

Add this state into the priority queue.

void push_queue (HEAP *queue, STATE *state, FLOAT32 worst_priority, FLOAT32 priority)
replace_char_widths

Replace the value of the char_width field in the chunks_record with the updated width measurements from the last_segmentation.

void replace_char_widths (CHUNKS_RECORD *chunks_record, SEARCH_STATE state)

Variables

int num_joints
int num_pushed = 0
int num_popped = 0
int wordrec_num_seg_states = 30
double wordrec_worst_state = 1

Function Documentation

void call_caller (  ) 
int chunks_gap ( WIDTH_RECORD width_record,
int  last_chunk 
)
int chunks_width ( WIDTH_RECORD width_record,
int  start_blob,
int  last_blob 
)
void delete_search ( SEARCH_RECORD the_search  ) 

delete_search

Terminate the current search and free all the memory involved.

SEARCH_RECORD* new_search ( CHUNKS_RECORD chunks_record,
int  num_joints,
WERD_CHOICE best_choice,
WERD_CHOICE raw_choice,
STATE state 
)
STATE* pop_queue ( HEAP queue  ) 
void push_queue ( HEAP queue,
STATE state,
FLOAT32  worst_priority,
FLOAT32  priority 
)
void replace_char_widths ( CHUNKS_RECORD chunks_record,
SEARCH_STATE  state 
)

Variable Documentation

int num_popped = 0
int num_pushed = 0

"Segmentation states"

double wordrec_worst_state = 1

"Worst segmentation state"

Generated on Sun Jul 18 17:10:52 2010 for Tesseract by  doxygen 1.6.3