Questions on converting output (HDF5) to common GPR formats

242 views
Skip to first unread message

Beth

unread,
Jul 11, 2018, 8:12:29 AM7/11/18
to gprMax-users
Dear all,

I used the Matlab script outputfile_converter.m to convert output into DZT format, but when I selected the outputfile, an error popped up:

Error using h5readc
Unable to open file. Filename may be corrupt or have unsupported characters.

Error in h5read (line 58)
[data, var_class] = h5readc(Filename,Dataset,start,count,stride);

Anyone encounter the same issue like me? My file name is 'trial.out' so I think it is supposed to be fine. Thankyou.


Dimitrios Angelis

unread,
Jul 11, 2018, 8:50:52 AM7/11/18
to gprMax-users
Hello Beth,

Just put your gprMax .out file in the same folder with the script.

Kind regards,
Dimitris
Message has been deleted

Beth

unread,
Jul 11, 2018, 9:31:32 AM7/11/18
to gprMax-users
Dear Dimitris,

After I choose the type of file to be converted, an error poped up:

Error in outputfile_converter (line348)
HDR.antenna = pad (HDR.antenna, 14, 'right');

Although there is a window pop up showing the file is exporting, it seems to be frozen. what should I do?

Best Regards,
Beth



Dimitrios Angelis

unread,
Jul 11, 2018, 9:52:38 AM7/11/18
to gprMax-users
Dear Beth,

I dont have any issues with the script. The error is probably due to a different Matlab version.

Can you provide me some info about your Matlab version? 

Beth

unread,
Jul 12, 2018, 3:09:44 AM7/12/18
to gprMax-users
Dear Dinitrios,

My Matlab is R2016a version

Craig Warren

unread,
Jul 12, 2018, 4:09:27 AM7/12/18
to gprMax-users
Hi Beth,

Can you attach the output file you experiencing problems with.

Kind regards,

Craig

Beth

unread,
Jul 12, 2018, 4:40:52 AM7/12/18
to gprMax-users
Dear Craig

Here are the outputs I am working on.

Best Regards,
Beth
Trial.zip

Craig Warren

unread,
Jul 12, 2018, 5:10:24 AM7/12/18
to gprMax-users
Hi Beth,

I tested both your output files with the converter script, and both worked OK for me (MATLAB R2018a). I suspect, as Dimitris indicated, it is something subtle with the version of MATLAB you are using. Can you copy/paste the exact error message you are getting.

Thanks,

Craig

Beth

unread,
Jul 12, 2018, 5:18:41 AM7/12/18
to gprMax-users
Dear Craig,

I really appreciate your help. Here are the error I have:

Warning: Default string does not match any button string name. 
Undefined function or variable 'pad'.

Error in outputfile_converter (line 348)
        HDR.antenna           = pad(HDR.antenna, 14, 'right');

Best Regards,
Beth

Craig Warren

unread,
Jul 12, 2018, 6:06:49 AM7/12/18
to gprMax-users
Hi Beth,

So your version of MATLAB (R2016a), does not have support for a lot of string functions. One of those is the pad function which the script uses. I have made a quick modification to the script which should workaround the problem for you. If you pull the latest version of gprMax from GitHub you'll get the updated script. 

Kind regards,

Craig

Beth

unread,
Jul 12, 2018, 8:14:59 AM7/12/18
to gprMax-users
Dear Craig & Dimitrio,

Thankyou for your help! It works! I really appreciate your help.

Best Regards,
Beth

moises stevend meza rodriguez

unread,
May 24, 2022, 3:46:59 PM5/24/22
to gprMax-users
Dear gprMax developers, I am using gprMAX (I'm a new user). I was wondering where I can find that script that you mention, It will definitely help me a lot in my project. This is my email to get in touch: moises....@gmail.com

Craig Warren

unread,
May 25, 2022, 10:29:33 AM5/25/22
to gprMax-users
You will find the 'outputfile_converter.m' script in the tools->MATLAB_scripts folder of the gprMax package.

Kind regards,
Craig

Reply all
Reply to author
Forward
0 new messages