CLI reference#
The sddb-cli console script wraps the same catalog queries as the Python API.
sddb-cli#
Query and download spatialdata-db datasets.
Usage:
$ sddb-cli [OPTIONS] COMMAND [ARGS]...
Options:
--help: Show this message and exit.
Commands:
query: List datasets matching the given facets.facets: List facet columns, or the distinct values…download: Download datasets to DEST and print the…viewer-url: Print the browser viewer link for a dataset.genes: List datasets expressing all GENES (one…cite: Write BibTeX for the studies of the…
sddb-cli query#
List datasets matching the given facets.
Usage:
$ sddb-cli query [OPTIONS]
Options:
--organism <str>--assay <str>--tissue <str>--disease <str>--technology <str>--tier <str>--validation <str>: ‘pass’ (default) or ‘all’. [default: pass]--gene, --expressing <str>: Gene symbol or Ensembl id; repeat to require all (downloads the gene index once).--min-fraction <float>: With –gene: min fraction_obs_detected.--search <str>: Free-text search over facet values.--min-obs <int>: Keep datasets with n_obs >= this.--min-features <int>: Keep datasets with n_features >= this.--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--json: Emit JSON records.--help: Show this message and exit.
sddb-cli facets#
List facet columns, or the distinct values of FIELD.
Usage:
$ sddb-cli facets [OPTIONS] [field]
Arguments:
field: Facet column; omit to list columns.
Options:
--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--help: Show this message and exit.
sddb-cli download#
Download datasets to DEST and print the manifest path.
Usage:
$ sddb-cli download [OPTIONS] {uids}...
Arguments:
uids...: Dataset uid(s). [required]
Options:
--dest <path>: Destination directory. [default: .]--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--workers <int>: Parallel downloads. [default: 4]--help: Show this message and exit.
sddb-cli viewer-url#
Print the browser viewer link for a dataset.
Usage:
$ sddb-cli viewer-url [OPTIONS] {uid}
Arguments:
uid: [required]
Options:
--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--help: Show this message and exit.
sddb-cli genes#
List datasets expressing all GENES (one gene: ranked by fraction of observations detected).
The first call downloads the cross-dataset gene index (~260 MB, one-time; cached afterwards).
Usage:
$ sddb-cli genes [OPTIONS] {genes}...
Arguments:
genes...: Gene symbol(s) or Ensembl id(s), case-insensitive. [required]
Options:
--limit <int>: Max datasets to list. [default: 20]--validation <str>: ‘all’ (default, includes bronze) or ‘pass’. [default: all]--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--help: Show this message and exit.
sddb-cli cite#
Write BibTeX for the studies of the datasets matching the given facets/search.
Usage:
$ sddb-cli cite [OPTIONS]
Options:
-o, --output <path>: BibTeX file to write. [required]--organism <str>--assay <str>--tissue <str>--disease <str>--technology <str>--tier <str>--search <str>: Free-text search over facet values.--validation <str>: ‘pass’ (default) or ‘all’. [default: pass]--bib-url <str>: citations.bib URL/path (default: next to the catalog).--catalog <str>: Catalog URL (default: $SDDB_CATALOG_URL).--help: Show this message and exit.