Command Line Interface

Run the workflow

usage: morphology-workflows [-h] [--version] [-c CONFIG_PATH] [-m]
                            [-ll {DEBUG,INFO,WARNING,ERROR,CRITICAL}]
                            [-lf LOG_FILE] [-w WORKERS]
                            [-dg CREATE_DEPENDENCY_GRAPH]
                            [-dgdpi DEPENDENCY_GRAPH_DPI]
                            {Initialize,Fetch,Placeholders,Curate,Annotate,Repair}
                            ...

Positional Arguments

workflow

Possible choices: Initialize, Fetch, Placeholders, Curate, Annotate, Repair

Possible workflows

Named Arguments

--version

show program’s version number and exit

-c, --config-path

Path to the Luigi config file.

-m, --master-scheduler

Use Luigi’s master scheduler instead of local scheduler.

Default: False

-ll, --log-level

Possible choices: DEBUG, INFO, WARNING, ERROR, CRITICAL

Logger level (this will ignore the luigi ‘logging_conf_file’ argument).

-lf, --log-file

Logger file.

-w, --workers

Number of workers that luigi can summon.

Default: 1

-dg, --create-dependency-graph

Create the dependency graph of a workflow instead of running it. Pass a path to render it as an image (depending on the extension of the given path).

-dgdpi, --dependency-graph-dpi

The DPI used for the dependency graph export.

Sub-commands

Initialize

Create default inputs for a given workflow that users can then update according to their needs. Usually, the initialization consists in one of these two types:

  • the morphologies are fetched from an online database.

  • the morphologies are provided by the user.

In the first case, the ‘–input-dir’ argument should usually not be used. In the second case, the ‘–source-database’ argument should usually not be used.

morphology-workflows Initialize [-h]
                                [--source-database {NeuroMorpho,BBP-Nexus,Allen,MouseLight}]
                                [--input-dir INPUT_DIR]
                                [--output-dir OUTPUT_DIR]
                                [--dataset-filename DATASET_FILENAME]

Named Arguments

--source-database

Possible choices: NeuroMorpho, BBP-Nexus, Allen, MouseLight

The database from which the morphologies will be fetched.

--input-dir

The directory containing the input morphologies if they are not fetched from a database.

--output-dir

The directory in which the project inputs will be exported.

--dataset-filename

The name of the CSV file to which the dataset will be exported.

Default: “dataset.csv”

Fetch

Fetch morphologies from the given source.

The JSON configuration file should contain a list of objects where each object is a config set:

[
    {
        "brain_region": "AHN",
        "nb_morphologies": 2,
        "seed": 0
    },
    {
        "brain_region": "VISp",
        "nb_morphologies": 2,
        "seed": 0
    }
]
morphology-workflows Fetch [-h] [--rerun] [--tag-output]
                           [--source FETCH_SOURCE]
                           [--config-file FETCH_CONFIG_FILE]
                           [--result-path FETCH_RESULT_PATH]

Named Arguments

--rerun

Trigger to force the task to rerun. Default value: False.

Default: False

--tag-output

(bool) Add a tag suffix to the output directory. Default value: False.

Default: False

--source

(str) The source used to download the morphologies Choices: {NeuroMorpho, BBP-Nexus, Allen, MouseLight}.

--config-file

(str) Path to the JSON config file

--result-path

(str) Path to the output directory. Default value: morphologies.

Placeholders

Compute the placeholders for a given region and mtype set from a given config.

morphology-workflows Placeholders [-h] [--rerun] [--tag-output]
                                  [--config PLACEHOLDERS_CONFIG]
                                  [--input-dir PLACEHOLDERS_INPUT_DIR]
                                  [--result-path PLACEHOLDERS_RESULT_PATH]
                                  [--nb-jobs PLACEHOLDERS_NB_JOBS]

Named Arguments

--rerun

Trigger to force the task to rerun. Default value: False.

Default: False

--tag-output

(bool) Add a tag suffix to the output directory. Default value: False.

Default: False

--config

(str) (optional) The path to the JSON config file.

--input-dir

(str) (optional) The directory containing the morphologies and their metadata file.

--result-path

(str) Path to the output file (can be CSV or JSON file). Default value: placeholders.csv.

--nb-jobs

(int) Number of jobs used by parallel tasks. Permitted values: int in [1, 10000000000). Default value: 1.

Curate

Run Curation phase.

(click on steps in the image for more details)

morphology-workflows Curate [-h] [--rerun] [--tag-output]
                            [--result-path CURATE_RESULT_PATH]
                            [--dataset-df CURATE_DATASET_DF]
                            [--data-dir CURATE_DATA_DIR]
                            [--custom-task-name CURATE_CUSTOM_TASK_NAME]
                            [--nb-processes CURATE_NB_PROCESSES]
                            [--redirect-stdout [CURATE_REDIRECT_STDOUT]]
                            [--report-path CURATE_REPORT_PATH]
                            [--generate-report [CURATE_GENERATE_REPORT]]
                            [--report-type CURATE_REPORT_TYPE]
                            [--report-config CURATE_REPORT_CONFIG]
                            [--specifications-only]

Named Arguments

--rerun

Trigger to force the task to rerun. Default value: False.

Default: False

--tag-output

(bool) Add a tag suffix to the output directory. Default value: False.

Default: False

--result-path

(str) (optional) Path to the global output directory.

--dataset-df

(str) (optional) Path to the input dataset.

--data-dir

(str) name of folder to store addittional files created by a task (the provided validation function must take this as argument). Default value: data.

--custom-task-name

(str) An optional custom name given to the task (the class name is used if not provided).

--nb-processes

(int) The number of parallel processes to use.

--redirect-stdout

(bool) Capture stdout from the validation function to make it work with progress bar. Disable it if you want to use PDB inside the validation function.

--report-path

(str) Path to the workflow report.

--generate-report

(bool) Trigger the report generation. Default value: True.

--report-type

(str) Type of report (‘pdf’: basic, ‘latexpdf’: beautiful). Choices: {pdf, latexpdf}. Default value: pdf.

--report-config

(dict) The configuration used by Sphinx to build the report.

--specifications-only

(bool) Only outputs the dataset specification document. Default value: False.

Default: False

Annotate

Run Annotation phase.

(click on steps in the image for more details)

morphology-workflows Annotate [-h] [--rerun] [--tag-output]
                              [--result-path ANNOTATE_RESULT_PATH]
                              [--dataset-df ANNOTATE_DATASET_DF]
                              [--data-dir ANNOTATE_DATA_DIR]
                              [--custom-task-name ANNOTATE_CUSTOM_TASK_NAME]
                              [--nb-processes ANNOTATE_NB_PROCESSES]
                              [--redirect-stdout [ANNOTATE_REDIRECT_STDOUT]]
                              [--report-path ANNOTATE_REPORT_PATH]
                              [--generate-report [ANNOTATE_GENERATE_REPORT]]
                              [--report-type ANNOTATE_REPORT_TYPE]
                              [--report-config ANNOTATE_REPORT_CONFIG]
                              [--specifications-only]

Named Arguments

--rerun

Trigger to force the task to rerun. Default value: False.

Default: False

--tag-output

(bool) Add a tag suffix to the output directory. Default value: False.

Default: False

--result-path

(str) (optional) Path to the global output directory.

--dataset-df

(str) (optional) Path to the input dataset.

--data-dir

(str) name of folder to store addittional files created by a task (the provided validation function must take this as argument). Default value: data.

--custom-task-name

(str) An optional custom name given to the task (the class name is used if not provided).

--nb-processes

(int) The number of parallel processes to use.

--redirect-stdout

(bool) Capture stdout from the validation function to make it work with progress bar. Disable it if you want to use PDB inside the validation function.

--report-path

(str) Path to the workflow report.

--generate-report

(bool) Trigger the report generation. Default value: True.

--report-type

(str) Type of report (‘pdf’: basic, ‘latexpdf’: beautiful). Choices: {pdf, latexpdf}. Default value: pdf.

--report-config

(dict) The configuration used by Sphinx to build the report.

--specifications-only

(bool) Only outputs the dataset specification document. Default value: False.

Default: False

Repair

Run Repair phase.

(click on steps in the image for more details)

morphology-workflows Repair [-h] [--rerun] [--tag-output]
                            [--result-path REPAIR_RESULT_PATH]
                            [--dataset-df REPAIR_DATASET_DF]
                            [--data-dir REPAIR_DATA_DIR]
                            [--custom-task-name REPAIR_CUSTOM_TASK_NAME]
                            [--nb-processes REPAIR_NB_PROCESSES]
                            [--redirect-stdout [REPAIR_REDIRECT_STDOUT]]
                            [--report-path REPAIR_REPORT_PATH]
                            [--generate-report [REPAIR_GENERATE_REPORT]]
                            [--report-type REPAIR_REPORT_TYPE]
                            [--specifications-only]

Named Arguments

--rerun

Trigger to force the task to rerun. Default value: False.

Default: False

--tag-output

(bool) Add a tag suffix to the output directory. Default value: False.

Default: False

--result-path

(str) (optional) Path to the global output directory.

--dataset-df

(str) (optional) Path to the input dataset.

--data-dir

(str) name of folder to store addittional files created by a task (the provided validation function must take this as argument). Default value: data.

--custom-task-name

(str) An optional custom name given to the task (the class name is used if not provided).

--nb-processes

(int) The number of parallel processes to use.

--redirect-stdout

(bool) Capture stdout from the validation function to make it work with progress bar. Disable it if you want to use PDB inside the validation function.

--report-path

(str) Path to the workflow report.

--generate-report

(bool) Trigger the report generation. Default value: True.

--report-type

(str) Type of report (‘pdf’: basic, ‘latexpdf’: beautiful). Choices: {pdf, latexpdf}. Default value: pdf.

--specifications-only

(bool) Only outputs the dataset specification document. Default value: False.

Default: False