Single entry point for all InVEST applications.
- class natcap.invest.cli.SelectModelAction(option_strings, dest, nargs=None, const=None, default=None, type=None, choices=None, required=False, help=None, metavar=None)¶
Given a possibly-ambiguous model string, identify the model to run.
This is a subclass of
argparse.Actionand is executed when the argparse interface detects that the user has attempted to select a model by name.
Build a json object of relevant information for the CLI.
The json object returned uses the human-readable model names for keys and the values are another dict containing the internal name of the model and the aliases recognized by the CLI.
A string representation of the JSON object.
Build a table of model names, aliases and other details.
This table is a table only in the sense that its contents are aligned into columns, but are not separated by a delimiter. This table is intended to be printed to stdout.
A string representation of the formatted table.
- natcap.invest.cli.export_to_python(target_filepath, model, args_dict=None)¶
CLI entry point for launching InVEST runs and other useful utilities.
This command-line interface supports two methods of launching InVEST models from the command-line:
through its GUI
in headless mode, without its GUI.
Running in headless mode allows us to bypass all GUI functionality, so models may be run in this way without having GUI packages installed.