physoce-datasets 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: physoce-datasets
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: A Python package and CLI for downloading various physical oceanographic datasets.
|
|
5
|
+
Requires-Python: >=3.12
|
|
6
|
+
Requires-Dist: cdsapi>=0.7.7
|
|
7
|
+
Requires-Dist: cfgrib>=0.9.15.1
|
|
8
|
+
Requires-Dist: click>=8.2.1
|
|
9
|
+
Requires-Dist: copernicusmarine>=2.3.0
|
|
10
|
+
Requires-Dist: ecmwf-datastores-client>=0.5.1
|
|
11
|
+
Requires-Dist: gcsfs>=2026.3.0
|
|
12
|
+
Requires-Dist: h5py>=3.16.0
|
|
13
|
+
Requires-Dist: ipykernel>=7.2.0
|
|
14
|
+
Requires-Dist: metpy>=1.7.1
|
|
15
|
+
Requires-Dist: numpy>=2.4.4
|
|
16
|
+
Requires-Dist: pycoare>=0.4.0
|
|
17
|
+
Requires-Dist: python-dotenv>=1.2.2
|
|
18
|
+
Requires-Dist: xarray[accel,io,parallel]>=2026.2.0
|
|
19
|
+
Description-Content-Type: text/markdown
|
|
20
|
+
|
|
21
|
+
# physoce-datasets
|
|
22
|
+
|
|
23
|
+
A Python package and CLI for downloading various physical oceanographic datasets.
|
|
24
|
+
|
|
25
|
+
## Install
|
|
26
|
+
|
|
27
|
+
Clone the package and navigate to the directory:
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
git clone https://github.com/andrew-s28/physoce-datasets.git
|
|
31
|
+
cd physoce-datasets
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### uv
|
|
35
|
+
|
|
36
|
+
`uv` is the preferred way to manage this package. Please refer to the [uv installation instructions](https://docs.astral.sh/uv/getting-started/installation/). Once uv is installed, you can initialize a virtual environment with `uv sync` or you can run any commands directly with `uv run` and `uv` will handle the `venv` creation and activation auto-magically.
|
|
37
|
+
|
|
38
|
+
### pip
|
|
39
|
+
|
|
40
|
+
Of course, you can also use the classic `pip`, but you have to handle creating and activating the `venv` yourself:
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
python -m venv .venv
|
|
44
|
+
source .venv/bin/activate
|
|
45
|
+
pip install -e .
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## Credentials
|
|
49
|
+
|
|
50
|
+
Upon usage, this package may prompt for credentials to various data stores. Please refer to their documentation for how to access credentials and how credentials are stored:
|
|
51
|
+
|
|
52
|
+
- [Copernicus Marine Services](https://toolbox-docs.marine.copernicus.eu/en/stable/usage/login-usage.html)
|
|
53
|
+
- [Copernicus Climate Data Store](https://cds.climate.copernicus.eu/how-to-api)
|
|
54
|
+
|
|
55
|
+
## CLI usage
|
|
56
|
+
|
|
57
|
+
Run the CLI with uv:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
uv run datasets.py --help
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Note that if you prefer the `pip` environment management, activate your environment according to the above and replace all `uv run` commands with `python`, e.g.:
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
python datasets.py --help
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Available commands:
|
|
70
|
+
|
|
71
|
+
- `eke`: Download altimetry-derived geostrophic velocities and compute eddy kinetic energy from Copernicus Marine Services.
|
|
72
|
+
- `era5`: ERA5 workflow group with `submit` and `download` subcommands.
|
|
73
|
+
|
|
74
|
+
Show command help:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
uv run datasets.py eke --help
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Options
|
|
81
|
+
|
|
82
|
+
All commands share the same base options:
|
|
83
|
+
|
|
84
|
+
- `--save-dir`: Directory where the dataset file is written. If not set, defaults to the package `data/` directory.
|
|
85
|
+
- `--start-date`: Start date in `YYYY-MM-DD` format. If not set, uses the earliest available date.
|
|
86
|
+
- `--end-date`: End date in `YYYY-MM-DD` format. If not set, uses the latest available date
|
|
87
|
+
|
|
88
|
+
Run `eke` download with defaults:
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
uv run datasets.py eke
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Submit ERA5 jobs with explicit options:
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
uv run datasets.py era5 submit --save-dir data --start-date 2020-01-01 --end-date 2020-01-31 --max-active-requests 10
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Download and process ERA5 files once all remote jobs are successful:
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
uv run datasets.py era5 download --save-dir data
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
The ERA5 workflow writes its progress to `submitted_requests.csv` inside the save directory. If the script exits or is interrupted, rerun the same command to resume from saved state.
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
physoce_datasets-0.1.0.dist-info/METADATA,sha256=_xo4MuuknfVz5FwDZjbBth52v0ES-cjsVi5QbJjWJEg,3343
|
|
2
|
+
physoce_datasets-0.1.0.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
|
|
3
|
+
physoce_datasets-0.1.0.dist-info/entry_points.txt,sha256=z0hEFYfrEXegyevzPJZ7nA_IUCjhBxHfEBp8osMBwbM,62
|
|
4
|
+
physoce_datasets-0.1.0.dist-info/RECORD,,
|