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

RE: Getting Started Tutorial

AU
Antonio Urti, modified 3 Years ago.

Getting Started Tutorial

Capillary Posts: 5 Join Date: 11/7/14 Recent Posts
Hello,

I am new to Xbeach and i have this problems.

I use the kings day release: 2015-10-22_XBeach_v1.22.4867_Kingsday_x64_netcdf_MPI. And the matlab toolbox: xbeach_release_10May2013.

Also I use MATLAB R2014a, and I istalled mpich2-1.4.1p1-win-x86-64.msi.

I generate a basic model but when i try to use xb_view it tells me that the directory does not exist. Hoever, all files are in this folder.


>> xbi = xb_generate_model;

>> xbr = xb_run(xbi);
Warning: Warning: the automatic retrieval of XBeach executables depend on daily builds that come from a build server.
Currently, the default XBeach build server is out of order. Therefore, executable obtained using this function may be from
ancient Rome.
> In xb_get_bin at 89
In xb_run at 123

>> xb_view(xbr)
Error using xb_read_dims (line 185)
directory or file "C:\Users\ANTONIO\Desktop\prova kingsday - Copia\xb_20161006194846\params.txt" does not exist

Error in xb_view>ui_read (line 500)
info.dims = xb_read_dims(info.fpath{i});

Error in xb_view>ui_build (line 134)
ui_read(obj);

Error in xb_view (line 127)
ui_build(fig);

Also, when i add this code from the tutorial I get this error: Undefined function or variable 'x'.

xbi = xb_generate_model( ...
'bathy', { 'x', x, 'z', z, 'xgrid', {'vardx', 0} }, ...
'waves', { 'Hm0', 9, 'Tp', 18 }, ...
'tide', { 'front', 5, 'back', 0 }, ...
'wavegrid', { 'nbins', 5 }, ...
'settings', { 'tstop', 7200, 'morfac', 5 });

I hope you can help me out,

Antonio Urti
KN
Kees Nederhoff, modified 3 Years ago.

RE: Getting Started Tutorial

Wind Posts: 41 Join Date: 3/3/14 Recent Posts
Hi Antonio,

To me, it seems these errors are more related to Matlab and/or the toolbox than to XBeach.

In your first error, you are trying to run your XBeach model with an executable from XBeach retrieved via the Matlab toolbox, but the toolbox cannot obtain a (new) version. Since you stated in your introduction you already downloaded the Kingsday release from the website, you can run your model by directly calling the XBeach executable. This can be done by creating a batch file with the following line in it: call "d:\path_to_XBeach\xbeach.exe".

In your second error it says that the params.txt does not exist, is this really the case? You can check if the file is there by using your windows explorer (or any other file browser).

For the third error, it seems that your Matlab does not have a variable called 'x' loaded. When you create your grid, there should be an x and a y matrix visible in your workspace. If you don't see that, could you maybe upload the full Matlab code you used to generate your model?

Cheers,
Kees
AU
Antonio Urti, modified 3 Years ago.

RE: Getting Started Tutorial

Capillary Posts: 5 Join Date: 11/7/14 Recent Posts
Hello,

I solved the problems related to the executable, and now the program works with the default settings. Now I'm trying to load the grid file and bathymetry of delft3d, but I can not. What are the files that I need to change and how?

thanks for help
LT
LARA TALAVERA, modified 3 Years ago.

RE: Getting Started Tutorial

Capillary Posts: 2 Join Date: 9/23/16 Recent Posts
Hi Antonio,

How did you solve the problem with the directory in which the program did not find the params.txt? I have the same problem when doing this and I have checked in the directory, and the params.txt is there, so I dont understand.

Thank youuu


>> xb_view(xbr)
Error using xb_read_dims (line 187)
directory or file "D:\Desktop\X-Beach\1953_stormsurge\xb_20161018194052\params.txt" does not
exist

Error in xb_view>ui_read (line 500)
info.dims = xb_read_dims(info.fpath{i});

Error in xb_view>ui_build (line 134)
ui_read(obj);

Error in xb_view (line 127)
ui_build(fig);
Arnold van Rooijen, modified 3 Years ago.

RE: Getting Started Tutorial

Swell Posts: 239 Join Date: 11/7/11 Recent Posts
Hi Antonio,

What do you mean with 'I can not'? Does the model crash?

You should be able to load a Delft3D Grid in XBeach, see the manual chapter 4 for more information.

Cheers,
Arnold