-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Daymet dataset added, * Bumping version to `v0.2.0`.
- Loading branch information
1 parent
03d742f
commit 6aa35ec
Showing
10 changed files
with
1,326 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,4 @@ | |
.git | ||
.ipynb_checkpoints | ||
.DS_Store | ||
|
||
*.swp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Changelog | ||
========= | ||
|
||
[v0.2.0] - May 5th, 2023 | ||
|
||
# Added | ||
* `Daymet` dataset based on https://daymet.ornl.gov/overview. | ||
|
||
# Changed | ||
* not applicable | ||
|
||
# Fixed | ||
* not applicable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.1.0 | ||
0.2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
; Meteorological Data Processing Workflow | ||
; Copyright (C) 2022, University of Saskatchewan | ||
; Copyright (C) 2023, University of Calgary | ||
; | ||
; This file is part of Meteorological Data Processing Workflow | ||
; | ||
; This program is free software: you can redistribute it and/or modify | ||
; it under the terms of the GNU General Public License as published by | ||
; the Free Software Foundation, either version 3 of the License, or | ||
; (at your option) any later version. | ||
; | ||
; This program is distributed in the hope that it will be useful, | ||
; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
; GNU General Public License for more details. | ||
; | ||
; You should have received a copy of the GNU General Public License | ||
; along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
; usage: | ||
; ncl 'coord_file="./path/to/wrf/coordinate/file.nc"' \ | ||
; 'minlat=float' \ | ||
; 'maxlat=float' \ | ||
; 'minlon=float' \ | ||
; 'maxlon=float' \ | ||
; coord_wrf_idx.ncl; | ||
|
||
;---suppress errors including fatal ones | ||
err = NhlGetErrorObjectId() | ||
|
||
setvalues err | ||
"errPrint" : "False" | ||
end setvalues | ||
|
||
;---coordinate variable path and and name must be entered as input arguments | ||
a = addfile(coord_file,"r") | ||
glat2d = a->lat | ||
glon2d = a->lon | ||
|
||
;---variable names below should be defined as input arguments | ||
; minlat | ||
; maxlat | ||
; minlon | ||
; maxlon | ||
; print("coord_file: "+coord_file) | ||
; print("minlat: "+minlat) | ||
; print("maxlat: "+maxlat) | ||
; print("minlon: "+minlon) | ||
; print("maxlon: "+maxlon) | ||
|
||
;---building arrays for getind_latlon2d () function | ||
lat = (/ minlat, maxlat /) | ||
lon = (/ minlon, maxlon /) | ||
|
||
;---Get xy indexes, and then use these to get lat/lon values back again. | ||
opt = True | ||
loc = getind_latlon2d (glat2d, glon2d, lat, lon) | ||
|
||
;---print the following array: [minlonidx, maxlonidx, minlatidx, maxlatidx] | ||
minlonidx = min(loc(:, 1)) | ||
maxlonidx = max(loc(:, 1)) | ||
minlatidx = min(loc(:, 0)) | ||
maxlatidx = max(loc(:, 0)) | ||
print(minlonidx+","+maxlonidx) | ||
print(minlatidx+","+maxlatidx) | ||
;---END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
; Meteorological Data Processing Workflow | ||
; Copyright (C) 2022, University of Saskatchewan | ||
; Copyright (C) 2023, University of Calgary | ||
; | ||
; This file is part of Meteorological Data Processing Workflow | ||
; | ||
; This program is free software: you can redistribute it and/or modify | ||
; it under the terms of the GNU General Public License as published by | ||
; the Free Software Foundation, either version 3 of the License, or | ||
; (at your option) any later version. | ||
; | ||
; This program is distributed in the hope that it will be useful, | ||
; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
; GNU General Public License for more details. | ||
; | ||
; You should have received a copy of the GNU General Public License | ||
; along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
; usage: | ||
; ncl 'coord_file="./path/to/wrf/coordinate/file.nc"' \ | ||
; 'minlat=float' \ | ||
; 'maxlat=float' \ | ||
; 'minlon=float' \ | ||
; 'maxlon=float' \ | ||
; coord_wrf_idx.ncl; | ||
|
||
;---suppress errors including fatal ones | ||
err = NhlGetErrorObjectId() | ||
|
||
setvalues err | ||
"errPrint" : "False" | ||
end setvalues | ||
|
||
;---coordinate variable path and and name must be entered as input arguments | ||
a = addfile(coord_file,"r") | ||
glat2d = a->lat | ||
glon2d = a->lon | ||
|
||
;---variable names below should be defined as input arguments | ||
; minlat | ||
; maxlat | ||
; minlon | ||
; maxlon | ||
; print("coord_file: "+coord_file) | ||
; print("minlat: "+minlat) | ||
; print("maxlat: "+maxlat) | ||
; print("minlon: "+minlon) | ||
; print("maxlon: "+maxlon) | ||
|
||
;---Get xy indexes, and then use these to get lat/lon values back again. | ||
opt = True | ||
loc = region_ind (glat2d, glon2d, minlat, maxlat, minlon, maxlon) | ||
|
||
;---print ERROR and exit of spatial index are out of range | ||
if (.not. all(loc)) then | ||
print("ERROR") | ||
exit | ||
end if | ||
|
||
;---print the following box of data: [minlonidx, maxlonidx, minlatidx, maxlatidx] | ||
minlonidx = loc(2) | ||
maxlonidx = loc(3) | ||
minlatidx = loc(0) | ||
maxlatidx = loc(1) | ||
print(minlonidx+","+maxlonidx) | ||
print(minlatidx+","+maxlatidx) | ||
;---END |
Oops, something went wrong.