Spacing is a process to add spaces between characters. This is a process that can be hard to get right, especially if it’s vital to get correct in some instances.
Spacing starts off with getting the space width ratio gathered between the two
W’s during training. The system then iterates through all the letter lines gotten by the OCR, and gets the gap between each character in pixels (Or from the beginning of the image to the first character). If a character requires a custom space, it is fetched in this loop as well and is set to be the distance ratio instead of the normal space.
After spacing is calculated, characters are re-ordered to ensure they are correctly placed, and the scanning is complete.