How to integrate a tool into the workspace#
Collect info#
A list of available toolsets is available at VForWaTer/curated-tools, where every toolset can contain several tools.
Collect information about tool parameters (using the example of tbr_skgstat)#
When you’re lucky you can find a documentation (e.g. https://mmaelicke.github.io/scikit-gstat/reference/variogram.html#skgstat.Variogram). If not, you have to get information directly from the code (and hope for inline documentation).
Important: Compare the needs of the tool with the definitions from the container (see below).
In future, all of this might be possible through the Docker tools:
The tools are bundled in Docker containers. Information is given in the respective containerized toolbox VForWaTer/tool_geostatistics
Accordingly, to get the parameters, do:
docker pull ghcr.io/vforwater/tbr_skgstat
docker run --rm -it tbr_skgstat bash cat /srv/tool.yml
or in case of problems use toolbox runner:
from toolbox_runner import list_tools
tools = list_tools() # dict with tool names as keys
krige_tool = tools.get('kriging') # it has to be present there...
krige_tool.title
krige_tool.description
krige_toool.parameters
Extremely helpful are examples given without the overhead of installing docker or toolbox_runner. These might be found directly in the tool: VForWaTer/tool_geostatistics
Define Tool#
The given parameters can now be used to fill the tool description in a python file. For details see existing tools in VForWaTer/vforwater-processes
How to use the tool in your process_run
function is hopefully also explained in the tool example (e.g. VForWaTer/tool_geostatistics)
Define Output#
Define output here …
Todo
Define the sections here