Handle the processing of inputs and outputs yourself¶
Algorithm templates rely heavily on both Docker and Python examples. These are commonly used containerization frameworks and programming languages. As a platform, Grand Challenge does not care if the container was a Docker image or if Python was used. The templates help speed up processing.
Creating the image completely yourself gets you fine-grained control over how inputs and outputs are read and written. But this also means that you need to know where to read the inputs from and where to write the outputs to. This is defined through so-called algorithm interfaces. Interfaces tell the Grand-Challenge platform what kind of data it has to deal with, and where to get or put it. You need to configure at least 1 and optionally more interfaces for your algorithm. You do this through the Interfaces
tab on your algorithm page. If you do not see this tab, get in touch with support@grand-challenge.org.
The general principle is that your Algorithm container will process one job at a time, and each job will process only one set of inputs. So you need to write your scripts to read that one set of inputs from a location in /input
and write your algorithm's outputs to a location in /output
. If your algorithm has multiple interfaces defined, and hence multiple possible input combinations, it is your responsibility to check which inputs are present and hence which output(s) need to be produced. More on interfaces here.
For some simple examples, for an algorithm with just 1 interface check the snippets on this demo algorithm template for examples in Python.