global_equiv_resol

The uw mode for configuring and running the UFS Utils preprocessing component global_equiv_resol. Documentation for this UFS Utils component is here.

uw global_equiv_resol --help
usage: uw global_equiv_resol [-h] [--version] TASK ...

Execute global_equiv_resol tasks

Optional arguments:
  -h, --help
      Show help and exit
  --version
      Show version info and exit

Positional arguments:
  TASK
    input_file
      Ensure the specified input grid file exists
    provisioned_run_directory
      Run directory provisioned with all required content
    run
      A run
    runscript
      The runscript
    validate
      Validate the UW driver config

All tasks take the same arguments. For example:

uw global_equiv_resol run --help
usage: uw global_equiv_resol run [-h] [--version] [--config-file PATH]
                                 [--batch] [--dry-run] [--graph-file PATH]
                                 [--key-path KEY[.KEY...]] [--quiet]
                                 [--verbose]

A run

Optional arguments:
  -h, --help
      Show help and exit
  --version
      Show version info and exit
  --config-file PATH, -c PATH
      Path to UW YAML config file (default: read from stdin)
  --batch
      Submit run to batch scheduler
  --dry-run
      Only log info, making no changes
  --graph-file PATH
      Path to Graphviz DOT output [experimental]
  --key-path KEY[.KEY...]
      Dot-separated path of keys leading through the config to the driver's
      configuration block
  --quiet, -q
      Print no logging messages
  --verbose, -v
      Print all logging messages

Examples

The examples use a configuration file named config.yaml with contents similar to:

global_equiv_resol:
  execution:
    batchargs:
      cores: 1
      walltime: "00:01:00"
    executable: /path/to/global_equiv_resol.exe
  input_grid_file: /path/to/input/grid/file
  run_dir: /path/to/dir/run
platform:
  account: me
  scheduler: slurm

Its contents are described in section global_equiv_resol.

  • Run global_equiv_resol on an interactive node

    $ uw global_equiv_resol run --config-file config.yaml
    

    The driver creates a runscript.global_equiv_resol file in the directory specified by run_dir: in the config and runs it, executing global_equiv_resol.

  • Run global_equiv_resol via a batch job

    $ uw global_equiv_resol run --config-file config.yaml --batch
    

    The driver creates a runscript.global_equiv_resol file in the directory specified by run_dir: in the config and submits it to the batch system. Running with --batch requires a correctly configured platform: block in config.yaml, as well as appropriate settings in the execution: block under global_equiv_resol:.

  • Specifying the --dry-run flag results in the driver logging messages about actions it would have taken, without actually taking any.

    $ uw global_equiv_resol run --config-file config.yaml --batch --dry-run
    
  • The --key-path option can be used to navigate from the top of the config to the driver’s configuration block. For example, specifying --key-path foo.bar with config

    foo:
      bar:
        driver:
          # driver config block
    

    is equivalent to using config

    driver:
      # driver config block
    

    without specifying --key-path.