ocrd_all icon indicating copy to clipboard operation
ocrd_all copied to clipboard

Draft for slim containers

Open joschrew opened this issue 2 years ago • 1 comments

Description: All processors run in their own docker-container as a processing-worker. Also there are containers: processing-server, rabbitmq and mongodb running. Executables for processors are delegators to ocrd network client.

Related issue: https://github.com/OCR-D/ocrd_all/issues/69#issuecomment-1600309509

Example usage:

Clone this repo: git clone [email protected]:joschrew/ocrd_all.git

Change to repository cd ocrd_all

Core, ocrd_cis and ocrd_tesserocr are needed for the example-run: git submodule update --init core/ ocrd_cis/ ocrd_tesserocr/

Create the venv and docker-compose.yaml: make -f Makefile-slim slim-venv

Create datadir (necessary to get the workspaces to the containers): mkdir data

Start the containers: docker-compose up -d

Get a workspace for testing:

curl "https://raw.githubusercontent.com/OCR-D/ocrd-webapi-implementation/main/things/example_ws.ocrd.zip" --output foo.zip
unzip foo.zip "data/*"

Activate the venv: . venv2/bin/activate

Run a processor on the workspace: ocrd-cis-ocropy-binarize -I OCR-D-IMG -O OCR-D-BIN -m mets.xml

joschrew avatar Jul 07 '23 14:07 joschrew

I have started the process of addressing all comments but this will take a while. I think I'll add them step by step. I will report back if that is finished.

joschrew avatar Jul 12 '23 15:07 joschrew