wrfrun 0.1.5__tar.gz → 0.1.6__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.
- wrfrun-0.1.6/.gitattributes +5 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/.gitignore +1 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/PKG-INFO +7 -4
- {wrfrun-0.1.5 → wrfrun-0.1.6}/README.md +6 -2
- {wrfrun-0.1.5 → wrfrun-0.1.6}/meson.build +1 -1
- {wrfrun-0.1.5 → wrfrun-0.1.6}/pyproject.toml +3 -3
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/data.py +7 -6
- wrfrun-0.1.6/wrfrun/extension/goos_sst/README.md +10 -0
- wrfrun-0.1.6/wrfrun/extension/littler/README.md +9 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/littler/utils.py +1 -1
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/meson.build +0 -1
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/geodata.py +1 -1
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/core.py +1 -1
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/__init__.py +1 -0
- wrfrun-0.1.6/wrfrun/res/job_scheduler/__init__.py +8 -0
- wrfrun-0.1.6/wrfrun/res/job_scheduler/meson.build +8 -0
- wrfrun-0.1.6/wrfrun/res/job_scheduler/pbs.template +6 -0
- wrfrun-0.1.6/wrfrun/res/job_scheduler/slurm.template +6 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/meson.build +1 -0
- wrfrun-0.1.5/.gitattributes +0 -3
- {wrfrun-0.1.5 → wrfrun-0.1.6}/LICENSE +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/main.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/config.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/constant.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/namelist.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/core/server.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/goos_sst.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/res/Vtable.ERA_GOOS_SST +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/res/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/res/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/goos_sst/utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/littler/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/littler/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/micaps/README.md +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/extension/utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/core.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/namelist.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/plot.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/run.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/scheme.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/ndown_utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/wps_utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/wrf_utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/model/utils/wrfda_utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/pbs.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/plot/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/plot/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/plot/wps.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/config.yaml.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/extension/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/extension/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/extension/plotgrids.ncl +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/geogrid/GEOGRID.SHAN_DONG_LANDUSE_SOIL_TOP.TBL +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/geogrid/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/geogrid/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/metgrid/METGRID.TBL +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/metgrid/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/metgrid/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/namelist.input.da_wrfvar.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/namelist.input.dfi.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/namelist.input.real.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/namelist.input.wrf.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/namelist.wps.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/namelist/parame.in.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/run.sh.template +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/ungrib/__init__.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/res/ungrib/meson.build +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/run.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/utils.py +0 -0
- {wrfrun-0.1.5 → wrfrun-0.1.6}/wrfrun/workspace.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: wrfrun
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.6
|
|
4
4
|
Summary: wrfrun is a comprehensive toolkit for managing and using WRF
|
|
5
5
|
Keywords: WRF
|
|
6
6
|
Author-Email: Syize <syizeliu@gmail.com>
|
|
@@ -18,7 +18,6 @@ Requires-Dist: PyYAML
|
|
|
18
18
|
Requires-Dist: pandas
|
|
19
19
|
Requires-Dist: f90nml
|
|
20
20
|
Requires-Dist: cdsapi
|
|
21
|
-
Requires-Dist: seafog
|
|
22
21
|
Requires-Dist: matplotlib
|
|
23
22
|
Requires-Dist: Cartopy
|
|
24
23
|
Requires-Dist: wrf-python
|
|
@@ -43,10 +42,14 @@ The following are the main features that wrfrun wants to achieve. These features
|
|
|
43
42
|
- Real-time parsing of WRF logs, feedback on simulation progress.
|
|
44
43
|
- Support for adding more functionality through extensions.
|
|
45
44
|
|
|
46
|
-
##
|
|
45
|
+
## Installation
|
|
47
46
|
|
|
48
47
|
Install using pip:
|
|
49
48
|
|
|
50
49
|
```bash
|
|
51
50
|
pip install wrfrun
|
|
52
|
-
```
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Documentation
|
|
54
|
+
|
|
55
|
+
Please check [Wiki](https://github.com/Syize/wrfrun/wiki).
|
|
@@ -16,10 +16,14 @@ The following are the main features that wrfrun wants to achieve. These features
|
|
|
16
16
|
- Real-time parsing of WRF logs, feedback on simulation progress.
|
|
17
17
|
- Support for adding more functionality through extensions.
|
|
18
18
|
|
|
19
|
-
##
|
|
19
|
+
## Installation
|
|
20
20
|
|
|
21
21
|
Install using pip:
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
24
|
pip install wrfrun
|
|
25
|
-
```
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Documentation
|
|
28
|
+
|
|
29
|
+
Please check [Wiki](https://github.com/Syize/wrfrun/wiki).
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
[build-system]
|
|
2
2
|
build-backend = "mesonpy"
|
|
3
|
-
requires = ["meson-python"
|
|
3
|
+
requires = ["meson-python"]
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "wrfrun"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.6"
|
|
8
8
|
readme = "README.md"
|
|
9
9
|
license = { text = "GPL-3.0-or-later" }
|
|
10
10
|
requires-python = '>=3.10'
|
|
@@ -14,7 +14,7 @@ maintainers = [
|
|
|
14
14
|
]
|
|
15
15
|
keywords = [ "WRF", ]
|
|
16
16
|
description = "wrfrun is a comprehensive toolkit for managing and using WRF"
|
|
17
|
-
dependencies = ["xarray", "netCDF4", "rich", "PyYAML", "pandas", "f90nml", "cdsapi", "
|
|
17
|
+
dependencies = ["xarray", "netCDF4", "rich", "PyYAML", "pandas", "f90nml", "cdsapi", "matplotlib", "Cartopy", "wrf-python", "cfgrib"]
|
|
18
18
|
|
|
19
19
|
[project.urls]
|
|
20
20
|
homepage = "https://github.com/Syize/wrfrun"
|
|
@@ -4,7 +4,7 @@ from os.path import exists, dirname
|
|
|
4
4
|
from typing import Union, List, Tuple
|
|
5
5
|
|
|
6
6
|
from pandas import date_range
|
|
7
|
-
from seafog import goos_sst_find_data
|
|
7
|
+
# from seafog import goos_sst_find_data
|
|
8
8
|
|
|
9
9
|
import cdsapi
|
|
10
10
|
|
|
@@ -315,9 +315,9 @@ def prepare_wps_input_data(area: Tuple[int, int, int, int]):
|
|
|
315
315
|
download_data(start_date, end_date, hour_step, area, f"{bg_save_path}/pressure.grib",
|
|
316
316
|
data_format="grib", data_type="pressure", overwrite=True)
|
|
317
317
|
|
|
318
|
-
logger.info(f"Download NearGOOS data...")
|
|
319
|
-
download_data(start_date, end_date, hour_step, area,
|
|
320
|
-
|
|
318
|
+
# logger.info(f"Download NearGOOS data...")
|
|
319
|
+
# download_data(start_date, end_date, hour_step, area,
|
|
320
|
+
# save_path=sst_save_path, data_type="goos", overwrite=True)
|
|
321
321
|
|
|
322
322
|
|
|
323
323
|
def download_data(
|
|
@@ -394,9 +394,10 @@ def download_data(
|
|
|
394
394
|
)
|
|
395
395
|
pressure_level = None
|
|
396
396
|
elif data_type == "goos":
|
|
397
|
+
logger.warning(f"NEAR-GOOS SST data hasn't been supported yet")
|
|
397
398
|
# download sst data
|
|
398
|
-
for _date in date_list:
|
|
399
|
-
|
|
399
|
+
# for _date in date_list:
|
|
400
|
+
# _ = goos_sst_find_data(_date, save_path=save_path)
|
|
400
401
|
|
|
401
402
|
return ""
|
|
402
403
|
else:
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# GOOS SST extension
|
|
2
|
+
|
|
3
|
+
This extension can replace SKT (SKin Temperature) values in ERA5 reanalysis data with the SST (Sea Surface Temperature) from GOOS (Global Ocean Observing System). A new GRIB file will be generated so you can input it to WRF through `ungrib.exe` and `metgrid.exe`.
|
|
4
|
+
|
|
5
|
+
A [Vtable file](res/Vtable.ERA_GOOS_SST) is also provided for `ungrib.exe`.
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- Replace SKT in ERA5 data with GOOS SST and write new data to a GRIB file.
|
|
10
|
+
- While only ERA5 data is tested, data from other sources is supported theoretically.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Little R extension
|
|
2
|
+
|
|
3
|
+
This extension can write data to `LITTLE_R` format for WRF data assimilation.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
- Provide `LittleR` class to write any data to `LITTLE_R` format.
|
|
8
|
+
- Write data to a zip file (end with `.zlr`, that is `Zipped Little R file`).
|
|
9
|
+
- Read data from the `.zlr` file, so you can create `LITTLE_R` file with the data.
|
|
@@ -14,7 +14,7 @@ def to_fstring(var: Union[int, float, bool, str], length: Union[int, Tuple[int,
|
|
|
14
14
|
:param var: Basic variable, can be one of the ``[int, float, bool, str]``.
|
|
15
15
|
:type var: Union[int, float, bool, str]
|
|
16
16
|
:param length: The length of the output string.
|
|
17
|
-
If the type of ``var`` is ``float``, the length must
|
|
17
|
+
If the type of ``var`` is ``float``, the length must contain two parameters ``(total length, decimal length)``.
|
|
18
18
|
:type length: Union[int, Tuple[int, int]]
|
|
19
19
|
:return: Converted string.
|
|
20
20
|
:rtype: str
|
|
@@ -44,7 +44,7 @@ def _get_clip_area(index_area: tuple[int, int, int, int], row_num: int, col_num:
|
|
|
44
44
|
Returns:
|
|
45
45
|
tuple[int, int, int, int]: Clip area.
|
|
46
46
|
"""
|
|
47
|
-
#
|
|
47
|
+
# calculate tile area
|
|
48
48
|
tile_area = (
|
|
49
49
|
col_num * tile_x + 1,
|
|
50
50
|
col_num * tile_x + tile_x,
|
|
@@ -57,7 +57,7 @@ def model_preprocess(exec_name: str, work_path: str):
|
|
|
57
57
|
copyfile(_file, f"{work_path}/{filename}")
|
|
58
58
|
|
|
59
59
|
|
|
60
|
-
def model_postprocess(output_dir: str, save_path: str, startswith: Union[None, str, Tuple[str]] = None, endswith: Union[None, str, Tuple[str]] = None,
|
|
60
|
+
def model_postprocess(output_dir: str, save_path: str, startswith: Union[None, str, Tuple[str, ...]] = None, endswith: Union[None, str, Tuple[str, ...]] = None,
|
|
61
61
|
outputs: Union[None, str, List[str]] = None, copy_only=True):
|
|
62
62
|
"""
|
|
63
63
|
Save the results and logs from the model.
|
wrfrun-0.1.5/.gitattributes
DELETED
|
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
|