module documentation

Command to add datasets to database.

This convencience command allows adding individual dataset specifications manually or several datasets at once from a JSON file. Note that this does not actually load the data. The data is fetched and loaded into memory on demand, i.e., when a user opens the data explorer.

This command works similar to the add_institutions and add_users commands. Here is the help output of the command lyprox add_datasets --help:

usage: lyprox add_datasets [-h] (--from-file FROM_FILE | --from-stdin)
                           [--year YEAR] [--institution INSTITUTION]
                           [--subsite SUBSITE] [--repo-name REPO_NAME]
                           [--ref REF] [--version] [-v {0,1,2,3}]
                           [--settings SETTINGS] [--pythonpath PYTHONPATH]
                           [--traceback] [--no-color] [--force-color]
                           [--skip-checks]

Command to add datasets to database from initial JSON data.

options:
  -h, --help            show this help message and exit
  --from-file FROM_FILE
                        Path to JSON file with list of risk models.
  --from-stdin          Use command line arguments to create a single risk
                        model.
  --year YEAR           Year of dataset.
  --institution INSTITUTION
                        Institution of dataset.
  --subsite SUBSITE     Subsite of dataset.
  --repo-name REPO_NAME
                        Name of repository.
  --ref REF             Reference of repository.
  --version             Show program's version number and exit.
  -v {0,1,2,3}, --verbosity {0,1,2,3}
                        Verbosity level; 0=minimal output, 1=normal output,
                        2=verbose output, 3=very verbose output
  --settings SETTINGS   The Python path to a settings module, e.g.
                        "myproject.settings.main". If this isn't provided, the
                        DJANGO_SETTINGS_MODULE environment variable will be
                        used.
  --pythonpath PYTHONPATH
                        A directory to add to the Python path, e.g.
                        "/home/djangoprojects/myproject".
  --traceback           Raise on CommandError exceptions.
  --no-color            Don't colorize the command output.
  --force-color         Force colorization of the command output.
  --skip-checks         Skip system checks.
Class Command Command to add datasets to database from initial JSON data.