---
# System prepended metadata

title: PR 559

---

# PR 559

## list-available

Die Liste ist super! Könnte man die noch irgendwie eingrenzen, sodass nur die verfügbaren Modelle für einen bestimmten Prozessor ausgegeben werden? Die wichtigsten Modelle stehen ja ganz oben, da musste ich erstmal eine Weile hinscrollen...

## list-installed

Das gibt bei mir einfach nur die Namen der Prozessoren aus
```
ocrd resmgr list-installed
ocrd-calamari-recognize

ocrd-anybaseocr-dewarp

ocrd-sbb-textline-detector

ocrd-kraken-segment

ocrd-tesserocr-recognize

ocrd-cis-ocropy-recognize

ocrd-anybaseocr-tiseg

ocrd-anybaseocr-layout-analysis

ocrd-kraken-recognize

ocrd-sbb-binarize

ocrd-typegroups-classifier

ocrd-anybaseocr-block-segmentation
```

Tesseract hatte ich ganz installiert, von Calamari und Ocropy jeweils ein Modell. Die müssten hier eigentlich aufgelistet werden?


## fremdes Modell

### erfolgreicher Download
```
ocrd resmgr download -n ocrd-tesserocr-recognize https://github.com/tesseract-ocr/tessdata/raw/master/fin.traineddata
19:38:48.664 INFO ocrd.cli.resmgr - No resources found in registry
19:38:48.664 INFO ocrd.cli.resmgr - Downloading unregistered resource https://github.com/tesseract-ocr/tessdata/raw/master/fin.traineddata
19:38:48.950 INFO ocrd.resource_manager._download_impl - Downloading https://github.com/tesseract-ocr/tessdata/raw/master/fin.traineddata
Downloading  [####################################]  100%
19:38:49.483 INFO ocrd.cli.resmgr - ocrd-tesserocr-recognize resource 'fin.traineddata' (https://github.com/tesseract-ocr/tessdata/raw/master/fin.traineddata) not a known resource, creating stub in /home/habocr/.config/ocrd/resources.yml'
19:38:49.485 INFO ocrd.cli.resmgr - Downloaded https://github.com/tesseract-ocr/tessdata/raw/master/fin.traineddata to /home/habocr/ocrd_all/venv/ocrd-resources/ocrd-tesserocr-recognize/fin.traineddata
19:38:49.485 INFO ocrd.cli.resmgr - Use in parameters as 'fin.traineddata'
```

### Modell nicht installiert
```
 ocrd-tesserocr-recognize -I OCR-D-SEG -O OCR-D-FIN -P model fin.traineddata
Traceback (most recent call last):
  File "/home/habocr/ocrd_all/venv/bin/ocrd-tesserocr-recognize", line 8, in <module>
    sys.exit(ocrd_tesserocr_recognize())
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_tesserocr/cli.py", line 43, in ocrd_tesserocr_recognize
    return ocrd_cli_wrap_processor(TesserocrRecognize, *args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd/decorators/__init__.py", line 90, in ocrd_cli_wrap_processor
    run_processor(processorClass, ocrd_tool, mets, workspace=workspace, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd/processor/helpers.py", line 72, in run_processor
    processor.process()
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_tesserocr/recognize.py", line 211, in process
    raise Exception("configured model " + sub_model + " is not installed")
Exception: configured model fin.traineddata is not installed
```

## Ocropy

```
ocrd-cis-ocropy-recognize -I OCR-D-SEG -O OCR-D-OCRO -P model fraktur-jze.pyrnn.gz
Traceback (most recent call last):
  File "/home/habocr/ocrd_all/venv/bin/ocrd-cis-ocropy-recognize", line 8, in <module>
    sys.exit(ocrd_cis_ocropy_recognize())
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_cis/ocropy/cli.py", line 48, in ocrd_cis_ocropy_recognize
    return ocrd_cli_wrap_processor(OcropyRecognize, *args, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd/decorators/__init__.py", line 90, in ocrd_cli_wrap_processor
    run_processor(processorClass, ocrd_tool, mets, workspace=workspace, **kwargs)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd/processor/helpers.py", line 63, in run_processor
    parameter=parameter
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_cis/ocropy/recognize.py", line 92, in __init__
    self.setup()
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_cis/ocropy/recognize.py", line 97, in setup
    self.network = load_object(self.get_model(), verbose=1)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_cis/ocropy/ocrolib/common.py", line 443, in load_object
    fname = ocropus_find_file(fname)
  File "/home/habocr/ocrd_all/venv/lib/python3.6/site-packages/ocrd_cis/ocropy/ocrolib/common.py", line 653, in ocropus_find_file
    raise FileNotFound(fname)
ocrd_cis.ocropy.ocrolib.exceptions.FileNotFound: file not found fraktur-jze.pyrnn.gz
```

funktioniert auch nicht nachdem ich das Modell nochmal gesondert mit `ocrd resmgr` heruntergeladen habe


## Calamari

## erfolgreicher Download

```
ocrd resmgr download ocrd-calamari-recognize qurator-gt4hist-1.0
19:55:44.702 INFO ocrd.cli.resmgr - Downloading resource {'url': 'https://qurator-data.de/calamari-models/GT4HistOCR/2019-12-11T11_10+0100/model.tar.xz', 'type': 'tarball', 'name': 'qurator-gt4hist-1.0', 'description': 'Calamari model trained with GT4HistOCR', 'size': 90275264, 'path_in_archive': '.', 'version_range': '>= 1.0.0', 'parameter_usage': 'as-is'}
19:55:44.703 INFO ocrd.resource_manager._download_impl - Downloading https://qurator-data.de/calamari-models/GT4HistOCR/2019-12-11T11_10+0100/model.tar.xz
  [####################################]  100%          19:55:46.222 INFO ocrd.resource_manager.download - Extracting tarball
19:55:51.924 INFO ocrd.resource_manager.download - Copying '.' from tarball to /home/habocr/ocrd_all/venv/ocrd-resources/ocrd-calamari-recognize/qurator-gt4hist-1.0

19:55:52.007 INFO ocrd.cli.resmgr - Downloaded https://qurator-data.de/calamari-models/GT4HistOCR/2019-12-11T11_10+0100/model.tar.xz to /home/habocr/ocrd_all/venv/ocrd-resources/ocrd-calamari-recognize/qurator-gt4hist-1.0
19:55:52.007 INFO ocrd.cli.resmgr - Use in parameters as 'qurator-gt4hist-1.0'
```

### Modell nicht verwendet

```
ocrd-calamari-recognize -I OCR-D-SEG -O OCR-D-CAL -P checkpoint_dir qurator-gt4hist-1.0
Traceback (most recent call last):
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/bin/ocrd-calamari-recognize", line 8, in <module>
    sys.exit(ocrd_calamari_recognize())
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/ocrd_calamari/cli.py", line 13, in ocrd_calamari_recognize
    return ocrd_cli_wrap_processor(CalamariRecognize, *args, **kwargs)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/ocrd/decorators/__init__.py", line 81, in ocrd_cli_wrap_processor
    run_processor(processorClass, ocrd_tool, mets, workspace=workspace, **kwargs)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/ocrd/processor/helpers.py", line 61, in run_processor
    parameter=parameter
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/ocrd_calamari/recognize.py", line 37, in __init__
    super(CalamariRecognize, self).__init__(*args, **kwargs)
  File "/home/habocr/ocrd_all/venv/local/sub-venv/headless-tf2/lib/python3.6/site-packages/ocrd/processor/base.py", line 66, in __init__
    raise Exception("Invalid parameters %s" % report.errors)
Exception: Invalid parameters ["[] Additional properties are not allowed ('checkpoint_dir' was unexpected)"]
```

