Skip to content

Getting started tutorial

jeipollack edited this page Mar 31, 2023 · 24 revisions

Welcome to the WaveDiff tutorial!

This tutorial serves as a walk-through guide of how to set up runs of WaveDiff with different configuration settings.

Basic Execution

The WaveDiff pipeline is launched and managed by wf_psf/run.py script.

A list of command-line arguments can be displayed using the --help option:

> python wf_psf/run.py --help
usage: run.py [-h] --conffile CONFFILE --repodir REPODIR --outputdir OUTPUTDIR

optional arguments:
  -h, --help            show this help message and exit
  --conffile CONFFILE, -c CONFFILE
                        a configuration file containing program settings.
  --repodir REPODIR, -r REPODIR
                        the path of the code repository directory.
  --outputdir OUTPUTDIR, -o OUTPUTDIR
                        the path of the output directory.

There are three arguments, which the user should specify when launching the pipeline.

The first argument: --confile CONFFILE specifies the path to the configuration file storing the parameter options for running the pipeline.

The second argument: --repodir REPODIR is the path to the WaveDiff repository.

The third argument: --outputdir OUTPUTDIR is used to set the path to the output directory, which stores the WaveDiff results.

To run WaveDiff, use the following command:

> python wf_psf/run.py -c /path/to/config/file -r /path/to/wf-psf -o /path/to/output/dir

Configuration

The input configuration files into WaveDiff are constructed using YAML (Yet Another Markup Language). There is the option to provide a single configuration file with all the parameter settings, but this could lead to a very lengthy file. The other option is to provide a set of configuration files for the each component of the WaveDiff pipeline, i.e. training, metrics evaluation, and plotting. In our implementation, we have a directory named config which stores the various sets of configuration files

config
├── configs.yaml
├── logging.conf
├── metrics_config.yaml
├── plotting_config.yaml
└── training_config.yaml

For example, the training part of the pipeline can contain all of the associated training parameters in a configuration file called training_config.yaml.
The exception is that for logging we use ini file syntax. There is the option to provide as an input a master file configs.yaml which lists the subcomponent configuration files.

---
  training_conf: config/training_config.yaml

Clone this wiki locally