Grid generation with Pyroms

Discussion about analysis, visualization, and collaboration tools and techniques

Moderators: arango, robertson

Post Reply
Message
Author
hetienne
Posts: 1
Joined: Wed Aug 18, 2010 9:58 pm
Location: CLS

Grid generation with Pyroms

#1 Unread post by hetienne »

Hello ROMS and Pyroms users.
I try to create a new ROMS grid using pyroms.
I don't have any trouble with horizontal grid.
I the use these code lines to generate vertical grid:
grd_name = 'W_AFRICA4'
grd_out='W_AFRICA4_grd.nc'
theta_b = 0.1
theta_s = 10.0
Tcline = 50
N = 40
vgrd = pyroms.vgrid.s_coordinate_4(hc, theta_b, theta_s, Tcline, N, hraw=hraw)
# ROMS grid
grd = pyroms.grid.ROMS_Grid(grd_name, hgrd, vgrd)
# write grid to netcdf file
pyroms.grid.write_ROMS_grid(grd, filename=grd_out)


When plotting, I obtain the following:
test_grid_test4.png
Then, if I try to load the grid (grid= pyroms.grid.get_ROMS_grid('W_AFRICA4')) and try to plot it again with the same script, the result is different:
test_grid_W_AFRICA4.png
Do someone have an idea of what happen?
Thank you for your help.

frederic
Posts: 3
Joined: Thu Oct 09, 2008 5:18 pm
Location: NCAR

Re: Grid generation with Pyroms

#2 Unread post by frederic »

Etienne,
Can you please check that the parameters (theta_b, theta_s, ...) in your gridid file are consistant with the parameters used to generate the vertical grid?
Thanks,
Frederic

Post Reply