General Usage Contents: Overview:

This document describes how to use Classnotes to parse scans and perform related options. To parse scans the user needs to have a profile describing the scanned text the user will be parsing. If there is no existing profile or the user needs to create a new profile see the Training Documentation for instructions on generating the new profile to use. Note that in the current version of Classnotes only uppercase and lowercase characters can be recognized and stored by the profile.

Selecting a Profile:

If the user has used the program before the default profile will be loaded at runtime. To change profiles use menu Profile -> Load Profile.

Parsing an Image (GUI):

First, open a color PNG image with File -> Open PNG. Note that a black and white or grayscale PNG image will NOT be displayed correctly (this may change in future versions of the program). Also note that when using the default program configuration parts of the scan that are not considered text, such as the lines on notebook paper, will be ignored. When parsing a scan, the default configuration searches for pixels within a certain interval of an all black pixel. To change this behavior, say to recognize a scan with blue ink, edit the interval in Misc -> Configuration under "Misc Config".

Next, setup the intervals (box) for what parts of the scan are parsed. To do this, edit Misc -> Configuration under "Parsing Config: Scan Ignore Edges". This is useful when there are parts of the image that are not text, but may be flagged as text, such as black lines around the edges of a scan or spots around the holes of a sheet of notebook paper. This interval will be shown as a dashed box around the body of the image. There are numerous other config options that can be tweaked for parsing (see Misc -> Configuration under "Parsing Config" and the Config Documentation).

Finally, click on Parsing -> Parse to parse the image. The parsed image will have boxes around the lines recognized in the scan and around each character recognized. The interpretted letters for each character are shown in the left corner of each character box. The final text including interpretted spaces is shown in the bottom text list by line number. This process can be repeated for as many scans as desired by the user.

Post-Parse Options (GUI):

There are several options for the newly parsed scan. To view stats on the parse including runners up for letter matching and the gridding for each character click on Parse -> Parse Stats. To add the results of the parsed scan to the current profile click on the menu item Parse -> Train With This Scan. This will bring up the training window and will allow for the correction of some mistaken characters. To clear out all parsed text click on Parse -> Clear All. Finally, the translated text can be save to file by clicking on File -> Save As and selecting a file to save.

Parsing Scans on the Commandline:

In addition to GUI-based parsing, it is possible to parse images on the commandline once the profile has been created with the training GUI. The list of available commandline options can be found in the README. The following paragraphs detail some example runs of the program.

To parse two files:

$ classnotes --scan-files /path/to/file1 /path/to/file2 --output-file-prefix prefix --profile /path/to/profile

This command parses bothe files and saves the ouput to separate files (with the given prefix).

To parse a directory of files from the configuration’s scan directory (this can be changed at runtime by editing the config file at "~/.classnotes/config") and save the output to a single file:

$ classnotes --parse-all-in-scan-dir --single-output-file output_file.txt --profile /path/to/profile

There are a couple of other combinations of the code but these examples demonstrate the basic idea. In addition to the README typing "classnotes --help" will list the supported options.

Changing Training Profiles:

In order to change the profile for one set of scans to the profile for another distinct set of scans click on the menu option Parse -> New Scan Set followed by the menu option Parse -> Enter Training. This will cause training to not only generate a new profile but also require the user to setup new intervals for spaces and line height. Note that when the new profile is written in the training GUI the user will be prompted for a name of the profile.

Viewing Program Logs:

When errors occur in the running of the program the errors are usually written to the log file (the log file and directory can be changed from the config file at "~/.classnotes/config" or within the GUI by the menu option Misc -> Configuration). Even when a popup describes the error, usually a more detailed explanation of the error is given in the logs. The logs can be viewed both in the main window and in the training GUI. For the main window the menu option Misc -> View Logs will bring up a dialog listing all if the errors for the current run of the program. To access the logs from training click on the button "View Logs".