rex

ResourceX Command Line Interface

rex [OPTIONS] COMMAND [ARGS]...

Options

--version

Show the version and exit.

-h5, --resource_h5 <resource_h5>

Required Path to Resource .h5 file

-o, --out_dir <out_dir>

Required Directory to dump output files

-log, --log_file <log_file>

Path to .log file, if None only log to stdout

-v, --verbose

Flag to turn on debug logging. Default is not verbose.

dataset

Extract a single dataset

rex dataset [OPTIONS] COMMAND [ARGS]...

Options

-d, --dataset <dataset>

Required Dataset to extract

box

Extract all pixels in the given bounding box

rex dataset box [OPTIONS]

Options

-ll1, --lat_lon_1 <lat_lon_1>

Required One corner of the bounding box

-ll2, --lat_lon_2 <lat_lon_2>

Required The other corner of the bounding box

-fs, --file_suffix <file_suffix>

File name suffix

-ts, --timestep <timestep>

Timestep to extract

multi-site

Extract multiple sites given in ‘–sites’ .csv or .json as “latitude”, “longitude” pairs OR “gid”s

rex dataset multi-site [OPTIONS]

Options

-s, --sites <sites>

Required .csv or .json file with columns “latitude”, “longitude” OR “gid”

region

Extract all pixels in the given region

rex dataset region [OPTIONS]

Options

-r, --region <region>

Required Region to extract

-col, --region_col <region_col>

Meta column to search for region

Default:

'state'

-ts, --timestep <timestep>

Timestep to extract

site

Extract the nearest pixel to the given (lat, lon) coordinates OR the given resource gid

rex dataset site [OPTIONS]

Options

-ll, --lat_lon <lat_lon>

(lat, lon) coordinates of interest

-gid, --gid <gid>

Resource gid of interest

sam-datasets

Extract all datasets needed for SAM for the nearest pixel(s) to the given (lat, lon) coordinates, the given resource gid, or the give sites

rex sam-datasets [OPTIONS]

Options

-ll, --lat_lon <lat_lon>

(lat, lon) coordinates of interest

-gid, --gid <gid>

Resource gid of interest

-s, --sites <sites>

.csv or .json file with columns “latitude”, “longitude” OR “gid”