|
| LSTMTrainer () |
|
| LSTMTrainer (FileReader file_reader, FileWriter file_writer, CheckPointReader checkpoint_reader, CheckPointWriter checkpoint_writer, const char *model_base, const char *checkpoint_name, int debug_interval, int64_t max_memory) |
|
virtual | ~LSTMTrainer () |
|
bool | TryLoadingCheckpoint (const char *filename, const char *old_traineddata) |
|
void | InitCharSet (const std::string &traineddata_path) |
|
void | InitCharSet (const TessdataManager &mgr) |
|
bool | InitNetwork (const STRING &network_spec, int append_index, int net_flags, float weight_range, float learning_rate, float momentum, float adam_beta) |
|
int | InitTensorFlowNetwork (const std::string &tf_proto) |
|
void | InitIterations () |
|
double | ActivationError () const |
|
double | CharError () const |
|
const double * | error_rates () const |
|
double | best_error_rate () const |
|
int | best_iteration () const |
|
int | learning_iteration () const |
|
int32_t | improvement_steps () const |
|
void | set_perfect_delay (int delay) |
|
const GenericVector< char > & | best_trainer () const |
|
double | NewSingleError (ErrorTypes type) const |
|
double | LastSingleError (ErrorTypes type) const |
|
const DocumentCache & | training_data () const |
|
DocumentCache * | mutable_training_data () |
|
Trainability | GridSearchDictParams (const ImageData *trainingdata, int iteration, double min_dict_ratio, double dict_ratio_step, double max_dict_ratio, double min_cert_offset, double cert_offset_step, double max_cert_offset, STRING *results) |
|
void | DebugNetwork () |
|
bool | LoadAllTrainingData (const GenericVector< STRING > &filenames, CachingStrategy cache_strategy, bool randomly_rotate) |
|
bool | MaintainCheckpoints (TestCallback tester, STRING *log_msg) |
|
bool | MaintainCheckpointsSpecific (int iteration, const GenericVector< char > *train_model, const GenericVector< char > *rec_model, TestCallback tester, STRING *log_msg) |
|
void | PrepareLogMsg (STRING *log_msg) const |
|
void | LogIterations (const char *intro_str, STRING *log_msg) const |
|
bool | TransitionTrainingStage (float error_threshold) |
|
int | CurrentTrainingStage () const |
|
bool | Serialize (SerializeAmount serialize_amount, const TessdataManager *mgr, TFile *fp) const |
|
bool | DeSerialize (const TessdataManager *mgr, TFile *fp) |
|
void | StartSubtrainer (STRING *log_msg) |
|
SubTrainerResult | UpdateSubtrainer (STRING *log_msg) |
|
void | ReduceLearningRates (LSTMTrainer *samples_trainer, STRING *log_msg) |
|
int | ReduceLayerLearningRates (double factor, int num_samples, LSTMTrainer *samples_trainer) |
|
bool | EncodeString (const STRING &str, GenericVector< int > *labels) const |
|
const ImageData * | TrainOnLine (LSTMTrainer *samples_trainer, bool batch) |
|
Trainability | TrainOnLine (const ImageData *trainingdata, bool batch) |
|
Trainability | PrepareForBackward (const ImageData *trainingdata, NetworkIO *fwd_outputs, NetworkIO *targets) |
|
bool | SaveTrainingDump (SerializeAmount serialize_amount, const LSTMTrainer *trainer, GenericVector< char > *data) const |
|
bool | ReadTrainingDump (const GenericVector< char > &data, LSTMTrainer *trainer) const |
|
bool | ReadSizedTrainingDump (const char *data, int size, LSTMTrainer *trainer) const |
|
bool | ReadLocalTrainingDump (const TessdataManager *mgr, const char *data, int size) |
|
void | SetupCheckpointInfo () |
|
bool | SaveTraineddata (const STRING &filename) |
|
void | SaveRecognitionDump (GenericVector< char > *data) const |
|
STRING | DumpFilename () const |
|
void | FillErrorBuffer (double new_error, ErrorTypes type) |
|
std::vector< int > | MapRecoder (const UNICHARSET &old_chset, const UnicharCompress &old_recoder) const |
|
| LSTMRecognizer () |
|
| ~LSTMRecognizer () |
|
int | NumOutputs () const |
|
int | training_iteration () const |
|
int | sample_iteration () const |
|
double | learning_rate () const |
|
LossType | OutputLossType () const |
|
bool | SimpleTextOutput () const |
|
bool | IsIntMode () const |
|
bool | IsRecoding () const |
|
bool | IsTensorFlow () const |
|
GenericVector< STRING > | EnumerateLayers () const |
|
Network * | GetLayer (const STRING &id) const |
|
float | GetLayerLearningRate (const STRING &id) const |
|
void | ScaleLearningRate (double factor) |
|
void | ScaleLayerLearningRate (const STRING &id, double factor) |
|
void | ConvertToInt () |
|
const UNICHARSET & | GetUnicharset () const |
|
const UnicharCompress & | GetRecoder () const |
|
const Dict * | GetDict () const |
|
void | SetIteration (int iteration) |
|
int | NumInputs () const |
|
int | null_char () const |
|
bool | Load (const char *lang, TessdataManager *mgr) |
|
bool | Serialize (const TessdataManager *mgr, TFile *fp) const |
|
bool | DeSerialize (const TessdataManager *mgr, TFile *fp) |
|
bool | LoadCharsets (const TessdataManager *mgr) |
|
bool | LoadRecoder (TFile *fp) |
|
bool | LoadDictionary (const char *lang, TessdataManager *mgr) |
|
void | RecognizeLine (const ImageData &image_data, bool invert, bool debug, double worst_dict_cert, const TBOX &line_box, PointerVector< WERD_RES > *words, int lstm_choice_mode=0) |
|
void | OutputStats (const NetworkIO &outputs, float *min_output, float *mean_output, float *sd) |
|
bool | RecognizeLine (const ImageData &image_data, bool invert, bool debug, bool re_invert, bool upside_down, float *scale_factor, NetworkIO *inputs, NetworkIO *outputs) |
|
STRING | DecodeLabels (const GenericVector< int > &labels) |
|
void | DisplayForward (const NetworkIO &inputs, const GenericVector< int > &labels, const GenericVector< int > &label_coords, const char *window_name, ScrollView **window) |
|
void | LabelsFromOutputs (const NetworkIO &outputs, GenericVector< int > *labels, GenericVector< int > *xcoords) |
|
|
void | InitCharSet () |
|
void | SetNullChar () |
|
void | EmptyConstructor () |
|
bool | DebugLSTMTraining (const NetworkIO &inputs, const ImageData &trainingdata, const NetworkIO &fwd_outputs, const GenericVector< int > &truth_labels, const NetworkIO &outputs) |
|
void | DisplayTargets (const NetworkIO &targets, const char *window_name, ScrollView **window) |
|
bool | ComputeTextTargets (const NetworkIO &outputs, const GenericVector< int > &truth_labels, NetworkIO *targets) |
|
bool | ComputeCTCTargets (const GenericVector< int > &truth_labels, NetworkIO *outputs, NetworkIO *targets) |
|
double | ComputeErrorRates (const NetworkIO &deltas, double char_error, double word_error) |
|
double | ComputeRMSError (const NetworkIO &deltas) |
|
double | ComputeWinnerError (const NetworkIO &deltas) |
|
double | ComputeCharError (const GenericVector< int > &truth_str, const GenericVector< int > &ocr_str) |
|
double | ComputeWordError (STRING *truth_str, STRING *ocr_str) |
|
void | UpdateErrorBuffer (double new_error, ErrorTypes type) |
|
void | RollErrorBuffers () |
|
STRING | UpdateErrorGraph (int iteration, double error_rate, const GenericVector< char > &model_data, TestCallback tester) |
|
void | SetRandomSeed () |
|
void | DisplayLSTMOutput (const GenericVector< int > &labels, const GenericVector< int > &xcoords, int height, ScrollView *window) |
|
void | DebugActivationPath (const NetworkIO &outputs, const GenericVector< int > &labels, const GenericVector< int > &xcoords) |
|
void | DebugActivationRange (const NetworkIO &outputs, const char *label, int best_choice, int x_start, int x_end) |
|
void | LabelsViaReEncode (const NetworkIO &output, GenericVector< int > *labels, GenericVector< int > *xcoords) |
|
void | LabelsViaSimpleText (const NetworkIO &output, GenericVector< int > *labels, GenericVector< int > *xcoords) |
|
const char * | DecodeLabel (const GenericVector< int > &labels, int start, int *end, int *decoded) |
|
const char * | DecodeSingleLabel (int label) |
|