Creating VDF files for a vertically stretched grid

1 post / 0 new
franslql_664945
Creating VDF files for a vertically stretched grid
Hi all,
I am new to Vapor (Version: 2.6.0) and I have run into a problem. 
I am trying to transform a netcdf file which contains several variables on 
a vertically stretched staggered grid to a vdf input file. My commands are:

ncdfvdfcreate -vars thl:buoy:sv:u:v:w -xcoordvar xt -ycoordvar yt -zcoordvar zt -gridtype
stretched -timedims time -timevars time concatenated1.007.nc test.vdf

ncdf2vdf -vars thl:buoy:sv:u:v:w -stagdims xm:ym:zm -timedims time -timevars time
concatenated1.007.nc test.vdf

If I leave the -vars out it for some reason only includes variable u.

I get the following output:
Created VDF file:
	Num time steps : 380
	3D Variable names : buoy sv thl u v w
	2DXY Variable names :
	2DXZ Variable names :
	2DYZ Variable names :
	Excluded 3D Variable names :
	Excluded 2D Variable names :
	Coordinate extents : 5 5 5 4995 4995 2732
Processing VDC time step 0
 Processing variable thl, data range (296.216, 309.413)
 Processing variable buoy, data range (-1.24805, 1.96576)
 Processing variable sv, data range (0, 0)
 Processing variable u, data range (-3.35967, 4.67914)
 Processing variable v, data range (-4.12834, 3.759)
Short read of variable "w" at time step 0
File closed before exactly 55 slices written
 Processing variable w, data range (-2.92581, 4.94771)
Processing VDC time step 1
GetVBasepath error, ts = 1 var = thl basepath =
Failed to open VDC variable "thl" at time step 1
 Processing variable thl, data range (-2.92581, 4.94771)
GetVBasepath error, ts = 1 var = buoy basepath =
Failed to open VDC variable "buoy" at time step 1
 Processing variable buoy, data range (-2.92581, 4.94771)
GetVBasepath error, ts = 1 var = sv basepath =
Failed to open VDC variable "sv" at time step 1
 Processing variable sv, data range (-2.92581, 4.94771)
GetVBasepath error, ts = 1 var = u basepath =
Failed to open VDC variable "u" at time step 1
 Processing variable u, data range (-2.92581, 4.94771)
GetVBasepath error, ts = 1 var = v basepath =
Failed to open VDC variable "v" at time step 1
 Processing variable v, data range (-2.92581, 4.94771)
GetVBasepath error, ts = 1 var = w basepath =
Failed to open VDC variable "w" at time step 1
 Processing variable w, data range (-2.92581, 4.94771)
Failed to copy 7 variables

If I leave the staggered option out, it does create the vdf files, but Vapor visualizes 
the data on an equidistant grid, instead of the specified stretched grid.

The structure of my netcdf file is given by (output of ncdump):
netcdf concatenated1.007 {
dimensions:
	xt = 500 ;
	xm = 500 ;
	yt = 500 ;
	zt = 55 ;
	zm = 55 ;
	time = UNLIMITED ; // (24 currently)
	ym = 500 ;
variables:
	float xt(xt) ;
		xt:longname = "West-East displacement of cell centers" ;
		xt:units = "m" ;
	float xm(xm) ;
		xm:longname = "West-East displacement of cell edges" ;
		xm:units = "m" ;
	float yt(yt) ;
		yt:longname = "South-North displacement of cell centers" ;
		yt:units = "m" ;
	float zt(zt) ;
		zt:longname = "Vertical displacement of cell centers" ;
		zt:units = "m" ;
	float zm(zm) ;
		zm:longname = "Vertical displacement of cell edges" ;
		zm:units = "m" ;
	float time(time) ;
		time:longname = "Time" ;
		time:units = "s" ;
		time:_FillValue = -999.f ;
	float u(time, zt, yt, xm) ;
		u:longname = "West-East velocity" ;
		u:units = "m/s" ;
		u:_FillValue = -999.f ;
	float w(time, zm, yt, xt) ;
		w:longname = "Vertical velocity" ;
		w:units = "m/s" ;
		w:_FillValue = -999.f ;
	float thl(time, zt, yt, xt) ;
		thl:longname = "Liquid water potential temperature above 300K" ;
		thl:units = "K" ;
		thl:_FillValue = -999.f ;
	float sv(time, zt, yt, xt) ;
		sv:longname = "passive scalar" ;
		sv:units = "-" ;
		sv:_FillValue = -999.f ;
	float buoy(time, zt, yt, xt) ;
		buoy:longname = "Buoyancy" ;
		buoy:units = "K" ;
		buoy:_FillValue = -999.f ;
	float v(time, zt, ym, xt) ;>
		v:longname = "South-North velocity" ;
		v:units = "m/s" ;
		v:_FillValue = -999.f ;
	float ym(ym) ;
		ym:longname = "South-North displacement of cell edges" ;
		ym:units = "m" ;

I hope someone can help me out.

Thank you in advance.