Prism is an efficient OCR written in C.
Convert scanned documents and images into editable text files.
sudo apt update
sudo apt install make
sudo apt install libgtk-3-dev
- Clone the repository.
git clone [email protected]:prismocr/ocr.git
- Compile the project.
cd ocr
make
./build/release/ocr [options]
Possible options :
- gui
- ocr [network_path] [image_path]
- sharpen [image_path]
- blur [image_path]
- rotate [image_path] [angle]
- skew_detect [image_path]
- auto_rotate [image_path]
- edge_detect [image_path]
- contrast [image_path] [delta]
- invert [image_path]
- network [xor/add]
- segmentation [image_path]
- network_load [network_path]
You have to have Unity at the root of the repository:
git clone https://github.com/ThrowTheSwitch/Unity.git
And then:
make test
Add the following code to .git/hooks/pre-commit
(create the file if not
already existing).
#!/bin/sh
STAGED_FILES=$(git diff --name-only --cached)
make format
git add ${STAGED_FILES}
And make it executable chmod +x .git/hooks/pre-commit
To compile and run the project there is a script available at ./scripts/valgrind.sh
./scripts/valgrind.sh [target] [program arguments]
For example to run the xor demo in debug:
./scripts/valgrind.sh debug network xor