bug message reminder

When adressing a model crash or bug, please remember to include an entire model setup in your post that reproduces the crash or exposes the bug. Also add the XBlog.txt file. This is necessary information for people that are trying to help you. Including your model setup can be achieved by adding the zipped run directory (excluding output) as an attachment to the post.

Forum

xb_read_output not reading NetCDFfiles

JW
Johnathan Woodruff, modified 1 Year ago.

xb_read_output not reading NetCDFfiles

Capillary Posts: 5 Join Date: 2/22/19 Recent Posts

Hello,

 

I am having trouble using the matlab toolbox to read .nc files from previous model runs. I am using v1.23.5527_XBeachX_win32_netcdf. I have attached my the netCDF output for a run along with the XBlog. When I type the command xbo = xb_read_output(pwd,'vars','H') for instance I get the following error:

Invalid field name: '_parameters_DATA'.

Error in xb_read_dims (line 123)
        XBdims.([info.Dataset(i).Name '_DATA']) = nc_varget(filename, info.Dataset(i).Name);

Error in xb_read_netcdf (line 149)
XBdims = xb_read_dims(fname);

Error in xb_read_output (line 97)
        variables = xb_read_netcdf(fname, varargin{:});

Error in xbeach_toolbox_viewer (line 4)
xbo0 = xb_read_output(pwd,'vars','H')

Thanks in advance!

 

Johnathan Woodruff

JW
Johnathan Woodruff, modified 1 Year ago.

RE: xb_read_output not reading NetCDFfiles

Capillary Posts: 5 Join Date: 2/22/19 Recent Posts

Hello All,

 

I found that the reason the matlab toolbox was not working properly was because I was using XBeachX. I reran everything with the Kingsday version and it works fine.

 

Johnathan 

CS
Constantin Schweiger, modified 1 Year ago.

RE: xb_read_output not reading NetCDFfiles

Wind Posts: 26 Join Date: 1/20/17 Recent Posts

Hi Johnathan,

you can still use the Matlab Toolbox with XBeachX. The only thing you have to do is using nc_varget(xboutput,'variable') instead of xb_read_output(...) as the latter doesn't work with XBeachX anymore.

Best regards,

Constantin

MG
Mandana Ghanavati, modified 2 Months ago.

RE: xb_read_output not reading NetCDFfiles

Capillary Posts: 5 Join Date: 1/1/20 Recent Posts
I have the same problem for 'xb_view('xboutput.nc')'.Invalid field name: '_parameters_DATA'.
what fuction should i use to show the result for xbeachx?