Installation
This project consists of both the inference and training code. Most users will only be interested in the inference part, so that the below only comprises of the inference part that you need to execute the plugin from within Xournal++.
The training part is optional and allows to help to train our own models which improve over time. This installation process is optional and detailed in the developer guide.
Linux
Run bash INSTALL_LINUX.sh from repository root directory.
This script also installs the plugin as explained in the last point of the cross-platform installation procedure. The installation of the plugin is performed with plugin/copy_to_plugin_folder.sh, which can also be invoked independently of INSTALL_LINUX.sh for updating the plugin installation.
Cross-platform
If you want to install the plugin manually, then execute the following commands:
- Install uv.
- Install HTRPipelines package into
external/htr_pipeline/HTRPipeline(seeINSTALL_LINUX.shfor the exact steps). - Install all dependencies with
uv sync. - Run the configuration script with
uv run xournalpp-htr-configure. - Install pre-commit hooks with:
uv run pre-commit install. - Copy
plugin/folder content to${XOURNAL_CONFIG_PATH}/plugins/xournalpp_htr/with${XOURNAL_CONFIG_PATH}being the configuration path of Xournal++, see Xournal++ manual here. - Edit
config.lua, setting_M.python_executableto the uv-managed Python executable and_M.xournalpp_htr_pathto the absolute path of this repo. See the example config for details inplugin/config.lua. - Ensure Xournal++ is on your
PATH. See here for the binary location.
After installation
Confirm that the installation worked by running make tests-installation from repository root directory.