ngiab-data-preprocess 4.6.2__tar.gz → 4.6.4__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 (54) hide show
  1. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/PKG-INFO +12 -3
  2. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/README.md +10 -2
  3. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/forcings.py +1 -2
  4. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/lstm-rust-realization-template.json +1 -1
  5. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/PKG-INFO +12 -3
  6. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/requires.txt +1 -0
  7. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/pyproject.toml +2 -1
  8. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/.github/pull_request_template.md +0 -0
  9. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/.github/workflows/build_only.yml +0 -0
  10. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/.github/workflows/publish.yml +0 -0
  11. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/.gitignore +0 -0
  12. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/LICENSE +0 -0
  13. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/ciroh-bgsafe.png +0 -0
  14. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/create_realization.py +0 -0
  15. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/dask_utils.py +0 -0
  16. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/dataset_utils.py +0 -0
  17. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/datasets.py +0 -0
  18. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/file_paths.py +0 -0
  19. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/gpkg_utils.py +0 -0
  20. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/graph_utils.py +0 -0
  21. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/s3fs_utils.py +0 -0
  22. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_processing/subset.py +0 -0
  23. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/cfe-nowpm-realization-template.json +0 -0
  24. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/cfe-template.ini +0 -0
  25. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/forcing_template.nc +0 -0
  26. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/lstm-catchment-template.yml +0 -0
  27. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/lstm-realization-template.json +0 -0
  28. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/ngen-routing-template.yaml +0 -0
  29. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/noah-owp-modular-init.namelist.input +0 -0
  30. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/source_validation.py +0 -0
  31. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/template.sql +0 -0
  32. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/data_sources/triggers.sql +0 -0
  33. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/__init__.py +0 -0
  34. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/__main__.py +0 -0
  35. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/css/console.css +0 -0
  36. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/css/main.css +0 -0
  37. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/css/toggle.css +0 -0
  38. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/js/console.js +0 -0
  39. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/js/data_processing.js +0 -0
  40. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/js/main.js +0 -0
  41. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/resources/loading.gif +0 -0
  42. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/static/resources/screenshot.jpg +0 -0
  43. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/templates/index.html +0 -0
  44. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/map_app/views.py +0 -0
  45. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_cli/__main__.py +0 -0
  46. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_cli/arguments.py +0 -0
  47. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_cli/custom_logging.py +0 -0
  48. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_cli/forcing_cli.py +0 -0
  49. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/SOURCES.txt +0 -0
  50. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/dependency_links.txt +0 -0
  51. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/entry_points.txt +0 -0
  52. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/modules/ngiab_data_preprocess.egg-info/top_level.txt +0 -0
  53. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/setup.cfg +0 -0
  54. {ngiab_data_preprocess-4.6.2 → ngiab_data_preprocess-4.6.4}/tests/test_nan_impute.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ngiab_data_preprocess
3
- Version: 4.6.2
3
+ Version: 4.6.4
4
4
  Summary: Graphical Tools for creating Next Gen Water model input data.
5
5
  Author-email: Josh Cunningham <jcunningham8@ua.edu>
6
6
  Project-URL: Homepage, https://github.com/CIROH-UA/NGIAB_data_preprocess
@@ -33,6 +33,7 @@ Requires-Dist: bokeh==3.5.1
33
33
  Requires-Dist: boto3
34
34
  Requires-Dist: numcodecs<0.16.0
35
35
  Requires-Dist: scipy>=1.15.3
36
+ Requires-Dist: h5py<=3.11
36
37
  Provides-Extra: eval
37
38
  Requires-Dist: ngiab_eval; extra == "eval"
38
39
  Provides-Extra: plot
@@ -239,6 +240,8 @@ Installed with uv: `uv run cli`
239
240
  - `-s`, `--subset`: Subset the hydrofabric to the given feature.
240
241
  - `-f`, `--forcings`: Generate forcings for the given feature.
241
242
  - `-r`, `--realization`: Create a realization for the given feature.
243
+ - `--lstm`: Configures the data for the [python lstm](https://github.com/ciroh-ua/lstm/).
244
+ - `--lstm_rust`: Configures the data for the [rust lstm](https://github.com/ciroh-ua/rust-lstm-1025/).
242
245
  - `--start_date START_DATE`, `--start START_DATE`: Start date for forcings/realization (format YYYY-MM-DD).
243
246
  - `--end_date END_DATE`, `--end END_DATE`: End date for forcings/realization (format YYYY-MM-DD).
244
247
  - `-o OUTPUT_NAME`, `--output_name OUTPUT_NAME`: Name of the output folder.
@@ -298,11 +301,17 @@ Installed with uv: `uv run cli`
298
301
 
299
302
  # Realization information
300
303
 
301
- This tool currently offers one default realization.
304
+ This tool currently offers three realizations.
302
305
 
303
- ## NOAH + CFE
306
+ ## NOAH + CFE (Default)
304
307
 
305
308
  [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/cfe-nowpm-realization-template.json) is intended to be roughly comparable to earlier versions of the National Water Model.
306
309
  - [NOAH-OWP-Modular](https://github.com/NOAA-OWP/NOAH-OWP-Modular): A refactoring of Noah-MP, a land-surface model. Used to model groundwater properties.
307
310
  - [Conceptual Functional Equivalent (CFE)](https://github.com/NOAA-OWP/CFE): A simplified conceptual approximation of versions 1.2, 2.0, and 2.1 of the National Water Model. Used to model precipitation and evaporation.
308
311
  - [SLoTH](https://github.com/NOAA-OWP/SLoTH): A module used to feed through unchanged values. In this default configuration, it simply forces certain soil moisture and ice fraction properties to zero.
312
+
313
+ ## LSTM (Python)
314
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-realization-template.json) will run the [python lstm](https://github.com/ciroh-ua/lstm/). It's designed to work with ngiab using [these example weights](https://github.com/CIROH-UA/lstm/tree/example_weights/trained_neuralhydrology_models) generously contributed by [jmframe/lstm](https://github.com/jmframe/lstm)
315
+
316
+ ## LSTM (Rust)
317
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-rust-realization-template.json) will run the [rust port](https://github.com/CIROH-UA/rust-lstm-1025/tree/main) of the python lstm above. It's an experimental drop in replacement that should produce identical results with a ~2-5x speedup depending on your setup.
@@ -198,6 +198,8 @@ Installed with uv: `uv run cli`
198
198
  - `-s`, `--subset`: Subset the hydrofabric to the given feature.
199
199
  - `-f`, `--forcings`: Generate forcings for the given feature.
200
200
  - `-r`, `--realization`: Create a realization for the given feature.
201
+ - `--lstm`: Configures the data for the [python lstm](https://github.com/ciroh-ua/lstm/).
202
+ - `--lstm_rust`: Configures the data for the [rust lstm](https://github.com/ciroh-ua/rust-lstm-1025/).
201
203
  - `--start_date START_DATE`, `--start START_DATE`: Start date for forcings/realization (format YYYY-MM-DD).
202
204
  - `--end_date END_DATE`, `--end END_DATE`: End date for forcings/realization (format YYYY-MM-DD).
203
205
  - `-o OUTPUT_NAME`, `--output_name OUTPUT_NAME`: Name of the output folder.
@@ -257,11 +259,17 @@ Installed with uv: `uv run cli`
257
259
 
258
260
  # Realization information
259
261
 
260
- This tool currently offers one default realization.
262
+ This tool currently offers three realizations.
261
263
 
262
- ## NOAH + CFE
264
+ ## NOAH + CFE (Default)
263
265
 
264
266
  [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/cfe-nowpm-realization-template.json) is intended to be roughly comparable to earlier versions of the National Water Model.
265
267
  - [NOAH-OWP-Modular](https://github.com/NOAA-OWP/NOAH-OWP-Modular): A refactoring of Noah-MP, a land-surface model. Used to model groundwater properties.
266
268
  - [Conceptual Functional Equivalent (CFE)](https://github.com/NOAA-OWP/CFE): A simplified conceptual approximation of versions 1.2, 2.0, and 2.1 of the National Water Model. Used to model precipitation and evaporation.
267
269
  - [SLoTH](https://github.com/NOAA-OWP/SLoTH): A module used to feed through unchanged values. In this default configuration, it simply forces certain soil moisture and ice fraction properties to zero.
270
+
271
+ ## LSTM (Python)
272
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-realization-template.json) will run the [python lstm](https://github.com/ciroh-ua/lstm/). It's designed to work with ngiab using [these example weights](https://github.com/CIROH-UA/lstm/tree/example_weights/trained_neuralhydrology_models) generously contributed by [jmframe/lstm](https://github.com/jmframe/lstm)
273
+
274
+ ## LSTM (Rust)
275
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-rust-realization-template.json) will run the [rust port](https://github.com/CIROH-UA/rust-lstm-1025/tree/main) of the python lstm above. It's an experimental drop in replacement that should produce identical results with a ~2-5x speedup depending on your setup.
@@ -312,7 +312,6 @@ def get_units(dataset: xr.Dataset) -> dict:
312
312
  units[var] = dataset[var].attrs["units"]
313
313
  return units
314
314
 
315
-
316
315
  def interpolate_nan_values(
317
316
  dataset: xr.Dataset,
318
317
  dim: str = "time",
@@ -345,7 +344,7 @@ def interpolate_nan_values(
345
344
  if not var.isnull().any().compute():
346
345
  continue
347
346
  logger.info("Interpolating NaN values in %s", name)
348
-
347
+ var = var.compute()
349
348
  dataset[name] = var.interpolate_na(
350
349
  dim=dim,
351
350
  method=method,
@@ -21,7 +21,7 @@
21
21
  "main_output_variable": "land_surface_water__runoff_depth",
22
22
  "uses_forcing_file": false,
23
23
  "registration_function": "register_bmi_lstm",
24
- "library_file": "/dmod/shared_libs/libbmi_burn_lstm.so"
24
+ "library_file": "/dmod/shared_libs/librust_lstm_1025.so"
25
25
  }
26
26
  }
27
27
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ngiab_data_preprocess
3
- Version: 4.6.2
3
+ Version: 4.6.4
4
4
  Summary: Graphical Tools for creating Next Gen Water model input data.
5
5
  Author-email: Josh Cunningham <jcunningham8@ua.edu>
6
6
  Project-URL: Homepage, https://github.com/CIROH-UA/NGIAB_data_preprocess
@@ -33,6 +33,7 @@ Requires-Dist: bokeh==3.5.1
33
33
  Requires-Dist: boto3
34
34
  Requires-Dist: numcodecs<0.16.0
35
35
  Requires-Dist: scipy>=1.15.3
36
+ Requires-Dist: h5py<=3.11
36
37
  Provides-Extra: eval
37
38
  Requires-Dist: ngiab_eval; extra == "eval"
38
39
  Provides-Extra: plot
@@ -239,6 +240,8 @@ Installed with uv: `uv run cli`
239
240
  - `-s`, `--subset`: Subset the hydrofabric to the given feature.
240
241
  - `-f`, `--forcings`: Generate forcings for the given feature.
241
242
  - `-r`, `--realization`: Create a realization for the given feature.
243
+ - `--lstm`: Configures the data for the [python lstm](https://github.com/ciroh-ua/lstm/).
244
+ - `--lstm_rust`: Configures the data for the [rust lstm](https://github.com/ciroh-ua/rust-lstm-1025/).
242
245
  - `--start_date START_DATE`, `--start START_DATE`: Start date for forcings/realization (format YYYY-MM-DD).
243
246
  - `--end_date END_DATE`, `--end END_DATE`: End date for forcings/realization (format YYYY-MM-DD).
244
247
  - `-o OUTPUT_NAME`, `--output_name OUTPUT_NAME`: Name of the output folder.
@@ -298,11 +301,17 @@ Installed with uv: `uv run cli`
298
301
 
299
302
  # Realization information
300
303
 
301
- This tool currently offers one default realization.
304
+ This tool currently offers three realizations.
302
305
 
303
- ## NOAH + CFE
306
+ ## NOAH + CFE (Default)
304
307
 
305
308
  [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/cfe-nowpm-realization-template.json) is intended to be roughly comparable to earlier versions of the National Water Model.
306
309
  - [NOAH-OWP-Modular](https://github.com/NOAA-OWP/NOAH-OWP-Modular): A refactoring of Noah-MP, a land-surface model. Used to model groundwater properties.
307
310
  - [Conceptual Functional Equivalent (CFE)](https://github.com/NOAA-OWP/CFE): A simplified conceptual approximation of versions 1.2, 2.0, and 2.1 of the National Water Model. Used to model precipitation and evaporation.
308
311
  - [SLoTH](https://github.com/NOAA-OWP/SLoTH): A module used to feed through unchanged values. In this default configuration, it simply forces certain soil moisture and ice fraction properties to zero.
312
+
313
+ ## LSTM (Python)
314
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-realization-template.json) will run the [python lstm](https://github.com/ciroh-ua/lstm/). It's designed to work with ngiab using [these example weights](https://github.com/CIROH-UA/lstm/tree/example_weights/trained_neuralhydrology_models) generously contributed by [jmframe/lstm](https://github.com/jmframe/lstm)
315
+
316
+ ## LSTM (Rust)
317
+ [This realization](https://github.com/CIROH-UA/NGIAB_data_preprocess/blob/main/modules/data_sources/lstm-rust-realization-template.json) will run the [rust port](https://github.com/CIROH-UA/rust-lstm-1025/tree/main) of the python lstm above. It's an experimental drop in replacement that should produce identical results with a ~2-5x speedup depending on your setup.
@@ -20,6 +20,7 @@ bokeh==3.5.1
20
20
  boto3
21
21
  numcodecs<0.16.0
22
22
  scipy>=1.15.3
23
+ h5py<=3.11
23
24
 
24
25
  [eval]
25
26
  ngiab_eval
@@ -19,7 +19,7 @@ filterwarnings = [
19
19
  ]
20
20
  [project]
21
21
  name = "ngiab_data_preprocess"
22
- version = "v4.6.2"
22
+ version = "v4.6.4"
23
23
  authors = [{ name = "Josh Cunningham", email = "jcunningham8@ua.edu" }]
24
24
  description = "Graphical Tools for creating Next Gen Water model input data."
25
25
  readme = "README.md"
@@ -52,6 +52,7 @@ dependencies = [
52
52
  "boto3",
53
53
  "numcodecs<0.16.0",
54
54
  "scipy>=1.15.3",
55
+ "h5py<=3.11"
55
56
  ]
56
57
 
57
58
  [project.optional-dependencies]