11. A computer program product comprising: non-transitory computer-readable medium storing instructions that, when executed by a computer, cause the computer to perform a method comprising: scanning an input image via an image input device; compressing the scanned image using an image compression tool by performing OCR (Optical Character Recognition) on the scanned image to generate OCR results and then performing tokenization on the scanned image using the OCR results, wherein the following rules are applied during the tokenization process: the symbols with different primary OCR results are not clustered into the same group; and for symbols with the same primary OCR result: if both symbols have high confidence levels for primary results and low confidence levels for secondary results, use a loose matching criteria to allow large shape variation; if both symbols have high confidence levels for primary results and at least one has a high confidence levels for its secondary results, use a tight matching criteria to avoid misclassification; if at least one symbol has a low confidence level for its primary result, use a moderate to tight matching criteria; and storing the compressed image in a storage device or printing the compressed image via an image output device after it has been decoded.
11. A computer program product comprising: non-transitory computer-readable medium storing instructions that, when executed by a computer, cause the computer to perform a method comprising: scanning an input image via an image input device; compressing the scanned image using an image compression tool by performing OCR (Optical Character Recognition) on the scanned image to generate OCR results and then performing tokenization on the scanned image using the OCR results, wherein the following rules are applied during the tokenization process: the symbols with different primary OCR results are not clustered into the same group; and for symbols with the same primary OCR result: if both symbols have high confidence levels for primary results and low confidence levels for secondary results, use a loose matching criteria to allow large shape variation; if both symbols have high confidence levels for primary results and at least one has a high confidence levels for its secondary results, use a tight matching criteria to avoid misclassification; if at least one symbol has a low confidence level for its primary result, use a moderate to tight matching criteria; and storing the compressed image in a storage device or printing the compressed image via an image output device after it has been decoded. 12. The computer program product defined in claim 11 , wherein the image compression tool comprises JBIG2.