Installation#

HedgeTools in python#

The plugin provides a Python API, making the algorithms accessible directly from your IDE.

Prerequisites#

  • QGIS >= 3.40 along with it’s python bindings

Virtual environment creation#

An environment with qgis bindings is needed. To create it easily i recommend using the qgis-venv-creator project by GipsoCoding.

In your terminal you can do the following :

qgis-venv-creator installation

Install using pipx: pipx install qgis-venv-creator

Or in an existing environment pip install qgis-venv-creator

Create your pyQgis environment

create-qgis-venv –venv-name “qgis_bindings.venv”

If multiple QGIS installation are detected the prompt will ask you to choose one.

Activate your venv

qgis_bindings.venv/Scripts/activate

You should be able to use qgis python bindings. And if you activate this environment in your IDE you should have autocompletion available.

You can then use HedgeTools inside your IDE. The documentation is available in the Python API section