wavespectra 4.4.0__tar.gz → 4.4.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.
Files changed (71) hide show
  1. {wavespectra-4.4.0/wavespectra.egg-info → wavespectra-4.4.1}/PKG-INFO +3 -3
  2. {wavespectra-4.4.0 → wavespectra-4.4.1}/pyproject.toml +2 -2
  3. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/__init__.py +1 -1
  4. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/swan.py +5 -2
  5. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/awac.py +1 -1
  6. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/ww3.py +1 -1
  7. {wavespectra-4.4.0 → wavespectra-4.4.1/wavespectra.egg-info}/PKG-INFO +3 -3
  8. {wavespectra-4.4.0 → wavespectra-4.4.1}/AUTHORS.rst +0 -0
  9. {wavespectra-4.4.0 → wavespectra-4.4.1}/LICENSE.txt +0 -0
  10. {wavespectra-4.4.0 → wavespectra-4.4.1}/README.rst +0 -0
  11. {wavespectra-4.4.0 → wavespectra-4.4.1}/setup.cfg +0 -0
  12. {wavespectra-4.4.0 → wavespectra-4.4.1}/setup.py +0 -0
  13. {wavespectra-4.4.0 → wavespectra-4.4.1}/tests/test_cli.py +0 -0
  14. {wavespectra-4.4.0 → wavespectra-4.4.1}/tests/test_cookiecutter_template.py +0 -0
  15. {wavespectra-4.4.0 → wavespectra-4.4.1}/tests/test_partition.py +0 -0
  16. {wavespectra-4.4.0 → wavespectra-4.4.1}/tests/test_specarray.py +0 -0
  17. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/cli.py +0 -0
  18. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/construct/__init__.py +0 -0
  19. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/construct/direction.py +0 -0
  20. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/construct/frequency.py +0 -0
  21. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/__init__.py +0 -0
  22. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/attributes.py +0 -0
  23. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/attributes.yml +0 -0
  24. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/fitting.py +0 -0
  25. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/npstats.py +0 -0
  26. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/select.py +0 -0
  27. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/utils.py +0 -0
  28. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/core/xrstats.py +0 -0
  29. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/__init__.py +0 -0
  30. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/dataset.py +0 -0
  31. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/datawell.py +0 -0
  32. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/era5.py +0 -0
  33. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/funwave.py +0 -0
  34. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/json.py +0 -0
  35. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/ncswan.py +0 -0
  36. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/ndbc.py +0 -0
  37. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/ndbc_ascii.py +0 -0
  38. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/netcdf.py +0 -0
  39. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/obscape.py +0 -0
  40. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/octopus.py +0 -0
  41. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/spotter.py +0 -0
  42. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/swan.py +0 -0
  43. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/triaxys.py +0 -0
  44. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/wavespectra.py +0 -0
  45. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/ww3.py +0 -0
  46. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/ww3_station.py +0 -0
  47. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/wwm.py +0 -0
  48. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/input/xwaves.py +0 -0
  49. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/__init__.py +0 -0
  50. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/funwave.py +0 -0
  51. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/json.py +0 -0
  52. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/netcdf.py +0 -0
  53. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/octopus.py +0 -0
  54. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/orcaflex.py +0 -0
  55. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/swan.py +0 -0
  56. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/output/ww3.yml +0 -0
  57. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/__init__.py +0 -0
  58. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/hanson_and_phillips_2001.py +0 -0
  59. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/partition.py +0 -0
  60. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/specpart/specpart.c +0 -0
  61. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/specpart/specpart.h +0 -0
  62. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/specpart/specpart_wrap.c +0 -0
  63. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/partition/tracking.py +0 -0
  64. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/plot.py +0 -0
  65. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/specarray.py +0 -0
  66. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra/specdataset.py +0 -0
  67. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra.egg-info/SOURCES.txt +0 -0
  68. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra.egg-info/dependency_links.txt +0 -0
  69. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra.egg-info/entry_points.txt +0 -0
  70. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra.egg-info/requires.txt +0 -0
  71. {wavespectra-4.4.0 → wavespectra-4.4.1}/wavespectra.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: wavespectra
3
- Version: 4.4.0
3
+ Version: 4.4.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>
@@ -37,12 +37,12 @@ Classifier: Topic :: Scientific/Engineering
37
37
  Classifier: Topic :: Scientific/Engineering :: Physics
38
38
  Classifier: Topic :: Scientific/Engineering :: Visualization
39
39
  Classifier: Programming Language :: Python :: 3
40
- Classifier: Programming Language :: Python :: 3.8
41
40
  Classifier: Programming Language :: Python :: 3.9
42
41
  Classifier: Programming Language :: Python :: 3.10
43
42
  Classifier: Programming Language :: Python :: 3.11
44
43
  Classifier: Programming Language :: Python :: 3.12
45
- Requires-Python: >=3.8
44
+ Classifier: Programming Language :: Python :: 3.13
45
+ Requires-Python: >=3.9
46
46
  Description-Content-Type: text/x-rst
47
47
  License-File: LICENSE.txt
48
48
  License-File: AUTHORS.rst
@@ -25,13 +25,13 @@ classifiers = [
25
25
  "Topic :: Scientific/Engineering :: Physics",
26
26
  "Topic :: Scientific/Engineering :: Visualization",
27
27
  "Programming Language :: Python :: 3",
28
- "Programming Language :: Python :: 3.8",
29
28
  "Programming Language :: Python :: 3.9",
30
29
  "Programming Language :: Python :: 3.10",
31
30
  "Programming Language :: Python :: 3.11",
32
31
  "Programming Language :: Python :: 3.12",
32
+ "Programming Language :: Python :: 3.13",
33
33
  ]
34
- requires-python = ">=3.8"
34
+ requires-python = ">=3.9"
35
35
  dependencies = [
36
36
  "click",
37
37
  "dask",
@@ -14,7 +14,7 @@ except ImportError:
14
14
  warnings.warn("Cannot import accessors at the main module level")
15
15
 
16
16
 
17
- __version__ = "4.4.0"
17
+ __version__ = "4.4.1"
18
18
 
19
19
 
20
20
  def _import_functions(pkgname="input", prefix="read"):
@@ -180,8 +180,11 @@ class SwanSpecFile(object):
180
180
  # Location
181
181
  strout += "{:40}{}\n".format("LONLAT", "locations in spherical coordinates")
182
182
  strout += "{:>6d}{:34}{}\n".format(len(self.x), "", "number of locations")
183
- for x, y in zip(self.x, self.y):
184
- strout += "{:2}{:<0.6f}{:2}{:<0.6f}\n".format("", x, "", y)
183
+ # Take care of lon/lat arrays with an extra singleton dimension
184
+ x_vals = np.atleast_1d(np.squeeze(self.x))
185
+ y_vals = np.atleast_1d(np.squeeze(self.y))
186
+ for x, y in zip(x_vals, y_vals):
187
+ strout += "{:2}{:<0.6f}{:2}{:<0.6f}\n".format("", float(x), "", float(y))
185
188
  # Frequency
186
189
  strout += "{:40}{}\n".format("AFREQ", "absolute frequencies in Hz")
187
190
  strout += "{:6d}{:34}{}\n".format(len(self.freqs), "", "number of frequencies")
@@ -450,7 +450,7 @@ def read_awac_strings(
450
450
 
451
451
  # Calculate m0 of the spectrum
452
452
  Sd = [np.sum(DirField[iFreq]) for iFreq in range(len(freq))]
453
- m0 = np.trapz(Sd, freq)
453
+ m0 = np.trapezoid(Sd, freq)
454
454
  Hs_spectrum = 4 * np.sqrt(m0)
455
455
 
456
456
  # scale the spectrum to the given Hs IF Hs_spectrum is not zero
@@ -82,7 +82,7 @@ def to_ww3(self, filename, ncformat="NETCDF4", compress=False):
82
82
  if var_name in other:
83
83
  other[var_name].attrs = var_attrs
84
84
  if "time" in other:
85
- other.time.encoding["units"] = TIME_UNITS
85
+ other.time.encoding.update(dtype="float64", units=TIME_UNITS)
86
86
  times = other.time.to_index().to_pydatetime()
87
87
  other.attrs.update(
88
88
  {
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: wavespectra
3
- Version: 4.4.0
3
+ Version: 4.4.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>
@@ -37,12 +37,12 @@ Classifier: Topic :: Scientific/Engineering
37
37
  Classifier: Topic :: Scientific/Engineering :: Physics
38
38
  Classifier: Topic :: Scientific/Engineering :: Visualization
39
39
  Classifier: Programming Language :: Python :: 3
40
- Classifier: Programming Language :: Python :: 3.8
41
40
  Classifier: Programming Language :: Python :: 3.9
42
41
  Classifier: Programming Language :: Python :: 3.10
43
42
  Classifier: Programming Language :: Python :: 3.11
44
43
  Classifier: Programming Language :: Python :: 3.12
45
- Requires-Python: >=3.8
44
+ Classifier: Programming Language :: Python :: 3.13
45
+ Requires-Python: >=3.9
46
46
  Description-Content-Type: text/x-rst
47
47
  License-File: LICENSE.txt
48
48
  License-File: AUTHORS.rst
File without changes
File without changes
File without changes
File without changes
File without changes