wavespectra 4.2.0__tar.gz → 4.2.1__tar.gz
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.
- {wavespectra-4.2.0/wavespectra.egg-info → wavespectra-4.2.1}/PKG-INFO +1 -1
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/__init__.py +1 -1
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/swan.py +3 -2
- {wavespectra-4.2.0 → wavespectra-4.2.1/wavespectra.egg-info}/PKG-INFO +1 -1
- {wavespectra-4.2.0 → wavespectra-4.2.1}/AUTHORS.rst +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/LICENSE.txt +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/README.rst +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/pyproject.toml +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/setup.cfg +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/setup.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/tests/test_cli.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/tests/test_cookiecutter_template.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/tests/test_partition.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/tests/test_specarray.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/cli.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/construct/__init__.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/construct/direction.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/construct/frequency.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/__init__.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/attributes.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/attributes.yml +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/fitting.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/npstats.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/select.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/swan.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/utils.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/core/xrstats.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/__init__.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/awac.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/dataset.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/datawell.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/era5.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/funwave.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/json.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/ncswan.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/ndbc.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/ndbc_ascii.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/netcdf.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/obscape.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/octopus.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/spotter.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/swan.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/triaxys.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/wavespectra.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/ww3.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/ww3_station.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/wwm.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/input/xwaves.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/__init__.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/funwave.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/json.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/netcdf.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/octopus.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/orcaflex.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/ww3.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/output/ww3.yml +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/__init__.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/hanson_and_phillips_2001.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/partition.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/specpart/specpart.c +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/specpart/specpart.h +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/specpart/specpart_wrap.c +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/partition/tracking.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/plot.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/specarray.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra/specdataset.py +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra.egg-info/SOURCES.txt +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra.egg-info/dependency_links.txt +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra.egg-info/entry_points.txt +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra.egg-info/requires.txt +0 -0
- {wavespectra-4.2.0 → wavespectra-4.2.1}/wavespectra.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: wavespectra
|
|
3
|
-
Version: 4.2.
|
|
3
|
+
Version: 4.2.1
|
|
4
4
|
Summary: Library for ocean wave spectra
|
|
5
5
|
Author-email: Wavespectra Developers <r.guedes@oceanum.science>
|
|
6
6
|
Maintainer-email: Rafael Guedes <r.guedes@oceanum.science>, Tom Durrant <t.durrant@oceanum.science>
|
|
@@ -41,7 +41,8 @@ def to_swan(
|
|
|
41
41
|
"""
|
|
42
42
|
# If grid reshape into site, otherwise ensure there is site dim to iterate over
|
|
43
43
|
dset = self._check_and_stack_dims()
|
|
44
|
-
|
|
44
|
+
time_size = dset.time.size if "time" in dset.dims else 1
|
|
45
|
+
ntime = min(ntime or time_size, time_size)
|
|
45
46
|
|
|
46
47
|
# Handle datasets with missing lon/lat
|
|
47
48
|
for arr, name in zip((lons, lats), (attrs.LONNAME, attrs.LATNAME)):
|
|
@@ -55,7 +56,7 @@ def to_swan(
|
|
|
55
56
|
# Ensure time dimension exists
|
|
56
57
|
is_time = attrs.TIMENAME in dset[attrs.SPECNAME].dims
|
|
57
58
|
if not is_time:
|
|
58
|
-
dset = dset.expand_dims({attrs.TIMENAME: [None]})
|
|
59
|
+
dset[attrs.SPECNAME] = dset[attrs.SPECNAME].expand_dims({attrs.TIMENAME: [None]})
|
|
59
60
|
times = dset[attrs.TIMENAME].values
|
|
60
61
|
else:
|
|
61
62
|
times = dset[attrs.TIMENAME].to_index().to_pydatetime()
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: wavespectra
|
|
3
|
-
Version: 4.2.
|
|
3
|
+
Version: 4.2.1
|
|
4
4
|
Summary: Library for ocean wave spectra
|
|
5
5
|
Author-email: Wavespectra Developers <r.guedes@oceanum.science>
|
|
6
6
|
Maintainer-email: Rafael Guedes <r.guedes@oceanum.science>, Tom Durrant <t.durrant@oceanum.science>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|