Skip to content

Commit

Permalink
[develop] Patch to correct a variable name to a lower-case (ufs-commu…
Browse files Browse the repository at this point in the history
…nity#468)

* Update plot_allvars.py

Updating a variable name "Geopotential Height" to "Geopotential height". Lower-case is needed for it to work with a newer Python.

* Update plot_allvars_diff.py

Updating a variable name "Geopotential Height" to "Geopotential height" (lower-case). This is needed to work with newer Python
  • Loading branch information
natalie-perlin authored Nov 14, 2022
1 parent 5356d1e commit b839658
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ush/Python/plot_allvars.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ def rotate_wind(true_lat,lov_lon,earth_lons,uin,vin,proj,inverse=False):
cin = data1.select(name='Convective inhibition',typeOfLevel='surface')[0].values

# 500 mb height, wind, vorticity
z500 = data1.select(name='Geopotential Height',level=500)[0].values * 0.1
z500 = data1.select(name='Geopotential height',level=500)[0].values * 0.1
z500 = ndimage.filters.gaussian_filter(z500, 6.89)
vort500 = data1.select(name='Absolute vorticity',level=500)[0].values * 100000
vort500 = ndimage.filters.gaussian_filter(vort500,1.7225)
Expand Down
4 changes: 2 additions & 2 deletions ush/Python/plot_allvars_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -383,9 +383,9 @@ def rotate_wind(true_lat,lov_lon,earth_lons,uin,vin,proj,inverse=False):
cin_diff = cin_2 - cin_1

# 500 mb height, wind, vorticity
z500_1 = data1.select(name='Geopotential Height',level=500)[0].values * 0.1
z500_1 = data1.select(name='Geopotential height',level=500)[0].values * 0.1
z500_1 = ndimage.filters.gaussian_filter(z500_1, 6.89)
z500_2 = data2.select(name='Geopotential Height',level=500)[0].values * 0.1
z500_2 = data2.select(name='Geopotential height',level=500)[0].values * 0.1
z500_2 = ndimage.filters.gaussian_filter(z500_2, 6.89)
z500_diff = z500_2 - z500_1
vort500_1 = data1.select(name='Absolute vorticity',level=500)[0].values * 100000
Expand Down

0 comments on commit b839658

Please sign in to comment.