OPeNDAP downloader
Library to facilitate data downloads from OPeNDAP services configured with a file size limitation.
This module will check if your requested file has a size under or above the file size limitation. If the size is under this limit, the file will be downloaded. Otherwise, the module will split the file (over time coordinates) in many files respecting the size limitation and download them. If output-file option is given, all the downloaded files will be concatenated into one and then be removed.
Installation
With pip:
pip install opendap-downloader
Usage
Command Line Interface (CLI)
Check-out usage and examples:
> opendap-downloader --help
Usage: opendap_downloader.py [OPTIONS]
Downloads OPeNDAP dataset as NetCDF files taking into account the server
data query limit.
Example:
opendap-downloader --dataset-url https://nrt.cmems-du.eu/thredds/dodsC/METOFFICE-GLO-SST-L4-NRT-OBS-SST-V2 --variable analysed_sst --variable sea_ice_fraction --temporal-subset 2021-01-01 2021-01-02 --geographical-subset 0.0 0.1 0.0 0.1
opendap-downloader -u https://nrt.cmems-du.eu/thredds/dodsC/METOFFICE-GLO-SST-L4-NRT-OBS-SST-V2 -v analysed_sst -v sea_ice_fraction -t 2021-01-01 2021-01-02 -g 0.0 0.1 0.0 0.1
Options:
-u, --dataset-url TEXT The full OPeNDAP dataset URL [required]
-v, --variable TEXT Specify dataset variables
-g, --geographical-subset <FLOAT RANGE FLOAT RANGE FLOAT RANGE FLOAT RANGE>...
The geographical subset as minimal latitude,
maximal latitude, minimal longitude and
maximal longitude
-t, --temporal-subset <DATETIME DATETIME>...
The temporal subset as start datetime and
end datetime
-d, --depth-range <FLOAT RANGE FLOAT RANGE>...
The depth range in meters, if depth is a
dataset coordinate
-o, --output-path PATH The destination path for the downloaded
files. Default is the current directory
[required]
-f, --output-file PATH Concatenate the downloaded data in the given
file name (under the output path)
-l, --limit INTEGER Specify the download size limit (in MB) of
the Opendap server if it can't be provided
by the message error
--confirmation Print dataset metadata and ask for
confirmation before download
--login TEXT
--password TEXT
--help Show this message and exit.
Contribute
Follow these instructions.
Metadata
Release files for opendap-downloader 0.9.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| opendap-downloader-0.9.0.tar.gz | 6.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| opendap_downloader-0.9.0-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details |
Total release size: 13.5 kB
Release files / opendap-downloader-0.9.0.tar.gz
| Download URL | opendap-downloader-0.9.0.tar.gz |
|---|---|
| Size | 6.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a3263d979a33708dab0e2b8a6c875f5c636b024efdade37f6485ae43e9466d5f
|
|
BLAKE2b-256 checksum How to use checksums |
3025a0c75b2d8d7e45cf2c61a5c375a1592ec630479664b2ded5fd97babad734
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.15
|
Release files / opendap_downloader-0.9.0-py2.py3-none-any.whl
| Download URL | opendap_downloader-0.9.0-py2.py3-none-any.whl |
|---|---|
| Size | 7.0 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
d7d0a91aef171e2e4dbd0ee2392d103ec71af78d8f0f555b4f5d444f2042486d
|
|
BLAKE2b-256 checksum How to use checksums |
069f08b701618fba65036551cffdef0750d897751d9b803266f6d8eb2dbf77aa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.15
|