<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>k-Wave User Forum &#187; Topic: Error reading h5 files when using binaries (MATLAB 2020a)</title>
		<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries</link>
		<description>Support for the k-Wave MATLAB toolbox</description>
		<language>en-US</language>
		<pubDate>Sat, 23 May 2026 20:28:33 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.k-wave.org/forum/search.php</link>
		</textInput>
		<atom:link href="http://www.k-wave.org/forum/rss/topic/error-reading-h5-files-when-using-binaries" rel="self" type="application/rss+xml" />

		<item>
			<title>Bradley Treeby on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8650</link>
			<pubDate>Tue, 08 Nov 2022 10:27:51 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">8650@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Noting this bug has been addressed in k-Wave v1.4
&#60;/p&#62;</description>
		</item>
		<item>
			<title>janee11 on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8586</link>
			<pubDate>Wed, 20 Jul 2022 09:33:57 +0000</pubDate>
			<dc:creator>janee11</dc:creator>
			<guid isPermaLink="false">8586@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;using R2022a, still works perfectly, did not need to download the patch
&#60;/p&#62;</description>
		</item>
		<item>
			<title>saturnnan on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8437</link>
			<pubDate>Wed, 26 Jan 2022 09:38:51 +0000</pubDate>
			<dc:creator>saturnnan</dc:creator>
			<guid isPermaLink="false">8437@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;The above error（Error: Invalid format of the input file: iostream error） will also appear in Matlab R2021a.&#60;br /&#62;
It can be solved according to the method （So in short, the work around is:&#60;br /&#62;
1. Open acousticFieldPropagator, writeAttributes, and writeMatrix in k-Wave...） provided by Treeby.&#60;br /&#62;
Thanks a lot.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Audrey Ntad on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8131</link>
			<pubDate>Tue, 20 Apr 2021 13:11:35 +0000</pubDate>
			<dc:creator>Audrey Ntad</dc:creator>
			<guid isPermaLink="false">8131@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hello,&#60;/p&#62;
&#60;p&#62;I am glad to find this discussion, I am actually using the k-wave toolbox with Matlab 2021a and have been encountering many issues such as errors in reading h5 files and some executables (kspaceFirstOrder3D-OMP.exe) stopping to work. Has anyone tried to solve these issues on the 2021a Mtlab version (I have the 1.2version of the toolbox).&#60;/p&#62;
&#60;p&#62;Thank you
&#60;/p&#62;</description>
		</item>
		<item>
			<title>satchit24 on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8111</link>
			<pubDate>Fri, 02 Apr 2021 06:04:21 +0000</pubDate>
			<dc:creator>satchit24</dc:creator>
			<guid isPermaLink="false">8111@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hello,&#60;br /&#62;
I have 2020b Version in windows 10. I tried to follow the steps as Bradley has mentioned but while writing those files it gives an error 'Access is Denied'. How to go about this error. Kindly let me know.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>marjanbn on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8072</link>
			<pubDate>Mon, 01 Mar 2021 19:09:47 +0000</pubDate>
			<dc:creator>marjanbn</dc:creator>
			<guid isPermaLink="false">8072@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hello,&#60;/p&#62;
&#60;p&#62;I could resolve my problem by changing the permission of the codes in the binaries folder. Since I am using a Linux system, I could do that by using the eclipse app, then through properties/permissions of the e.g., kspaceFirstOrder-CUDA file, I clicked on Execute for User.&#60;/p&#62;
&#60;p&#62;Hope it helps and thanks for your fantastic toolbox.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>SamPichardo on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8067</link>
			<pubDate>Wed, 24 Feb 2021 18:37:04 +0000</pubDate>
			<dc:creator>SamPichardo</dc:creator>
			<guid isPermaLink="false">8067@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Just to say that these latest versions of Matlab have become a nightmare to read HDF5 files, files generated in Python-based libraries (h5py) make now crash Matlab completely, when before it was completely ok.&#60;/p&#62;
&#60;p&#62;MATLAB crash file:C:\Users\samme\AppData\Local\Temp\matlab_crash_dump.31768-1:&#60;/p&#62;
&#60;p&#62;--------------------------------------------------------------------------------&#60;br /&#62;
             Access violation detected at 2021-02-24 10:34:28 -0700&#60;br /&#62;
--------------------------------------------------------------------------------&#60;/p&#62;
&#60;p&#62;Configuration:&#60;br /&#62;
  Crash Decoding           : Disabled - No sandbox or build area path&#60;br /&#62;
  Crash Mode               : continue (default)&#60;br /&#62;
  Default Encoding         : windows-1252&#60;br /&#62;
  Deployed                 : false&#60;br /&#62;
  Graphics Driver          : Unknown hardware&#60;br /&#62;
  Graphics card 1          : Intel Corporation ( 0x8086 ) Intel(R) UHD Graphics 630 Version 30.20.100.9314 (2021-2-12)&#60;br /&#62;
  Graphics card 2          : NVIDIA ( 0x10de ) NVIDIA GeForce RTX 2080 SUPER Version 27.21.14.6542 (2021-1-23)&#60;br /&#62;
  Java Version             : Java 1.8.0_202-b08 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode&#60;br /&#62;
  MATLAB Architecture      : win64&#60;br /&#62;
  MATLAB Entitlement ID    : 3294103&#60;br /&#62;
  MATLAB Root              : C:\Program Files\MATLAB\R2020b&#60;br /&#62;
  MATLAB Version           : 9.9.0.1592791 (R2020b) Update 5&#60;br /&#62;
  OpenGL                   : hardware&#60;br /&#62;
  Operating System         : Microsoft Windows 10 Home Insider Preview&#60;br /&#62;
  Process ID               : 31768&#60;br /&#62;
  Processor ID             : x86 Family 6 Model 158 Stepping 13, GenuineIntel&#60;br /&#62;
  Session Key              : 018388dd-f82e-4a1d-8d88-162c6fc40c86&#60;br /&#62;
  Window System            : Version 10.0 (Build 21318)&#60;/p&#62;
&#60;p&#62;Fault Count: 1&#60;/p&#62;
&#60;p&#62;Abnormal termination:&#60;br /&#62;
Access violation&#60;/p&#62;
&#60;p&#62;Current Thread: 'MCR 0 interpreter thread' id 3300&#60;/p&#62;
&#60;p&#62;Register State (from fault):&#60;br /&#62;
  RAX = 0000000000000001  RBX = 0000000000000000&#60;br /&#62;
  RCX = 000001e13c124280  RDX = 0000000000000000&#60;br /&#62;
  RSP = 0000006b37bf81f0  RBP = 0000000000000001&#60;br /&#62;
  RSI = 000001e12f2a2140  RDI = 000000000300013c&#60;/p&#62;
&#60;p&#62;   R8 = 0000000000000001   R9 = 000001e12a8b3ca0&#60;br /&#62;
  R10 = 00000000000001e0  R11 = 000001e135b897a0&#60;br /&#62;
  R12 = 0000000004000003  R13 = 0000000000000002&#60;br /&#62;
  R14 = 000001e127d9b280  R15 = 0000000000000008&#60;/p&#62;
&#60;p&#62;  RIP = 00007ffb68c417a3  EFL = 00010256&#60;/p&#62;
&#60;p&#62;   CS = 0033   FS = 0053   GS = 002b&#60;/p&#62;
&#60;p&#62;Stack Trace (from fault):&#60;br /&#62;
[  0] 0x00007ffb68c417a3 C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00071587 mexfilerequiredapiversion+00018067&#60;br /&#62;
[  1] 0x00007ffb68c3c07e C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00049278&#60;br /&#62;
[  2] 0x00007ffb68c3c380 C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00050048&#60;br /&#62;
[  3] 0x00007ffb68c38c2c C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00035884&#60;br /&#62;
[  4] 0x00007ffb68c39ec9 C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00040649&#60;br /&#62;
[  5] 0x00007ffb68c3d08f C:\Program Files\MATLAB\R2020b\toolbox\matlab\imagesci\private\hdf5infoc.mexw64+00053391 mexFunction+00000335&#60;br /&#62;
[  6] 0x00007ffb8bf2a289 C:\Program Files\MATLAB\R2020b\bin\win64\libmex.dll+00565897 mexfile::Inspector::needs_upgrade+00015977&#60;br /&#62;
[  7] 0x00007ffb8bf2b67b C:\Program Files\MATLAB\R2020b\bin\win64\libmex.dll+00571003 MexRetrieveVersion+00003579&#60;br /&#62;
[  8] 0x00007ffb8bf2b9b4 C:\Program Files\MATLAB\R2020b\bin\win64\libmex.dll+00571828 MexRetrieveVersion+00004404&#60;br /&#62;
[  9] 0x00007ffb8bf0c209 C:\Program Files\MATLAB\R2020b\bin\win64\libmex.dll+00442889 mexUnlock_800+00023993&#60;br /&#62;
[ 10] 0x00007ffb8c5626c1                     bin\win64\pgo\m_dispatcher.dll+00665281 Mfh_file::dispatch_file_common+00000165&#60;br /&#62;
[ 11] 0x00007ffb8c561d62                     bin\win64\pgo\m_dispatcher.dll+00662882 Mfh_error::lookup+00006498&#60;br /&#62;
[ 12] 0x00007ffb8c562615                     bin\win64\pgo\m_dispatcher.dll+00665109 Mfh_file::dispatch+00000045&#60;br /&#62;
[ 13] 0x00007ffb8953c08f                            bin\win64\pgo\m_lxe.dll+00770191 CGGBuiltinImpl+00361103&#60;br /&#62;
[ 14] 0x00007ffb89627d92                            bin\win64\pgo\m_lxe.dll+01736082 MathWorks::lxe::ShutdownLxeEngine+00090818&#60;br /&#62;
[ 15] 0x00007ffb89627bff                            bin\win64\pgo\m_lxe.dll+01735679 MathWorks::lxe::ShutdownLxeEngine+00090415&#60;br /&#62;
[ 16] 0x00007ffb895156b4                            bin\win64\pgo\m_lxe.dll+00612020 CGGBuiltinImpl+00202932&#60;br /&#62;
[ 17] 0x00007ffb8964173d                            bin\win64\pgo\m_lxe.dll+01840957 mwboost::archive::detail::oserializer&#38;lt;mwboost::archive::binaryTerm_oarchive,MathWorks::lxe::ClosedAbstractionFunctionDescriptorOwningIrTree&#38;gt;::oserializer&#38;lt;mwboost::archive::binaryTerm_oarchive,MathWorks::lxe::ClosedAbstractionFunctionDescriptorOwningIrTree&#38;gt;+00033337&#60;br /&#62;
[ 18] 0x00007ffb8951944d                            bin\win64\pgo\m_lxe.dll+00627789 CGGBuiltinImpl+00218701&#60;br /&#62;
[ 19] 0x00007ffb8951871d                            bin\win64\pgo\m_lxe.dll+00624413 CGGBuiltinImpl+00215325&#60;br /&#62;
[ 20] 0x00007ffb895069b7                            bin\win64\pgo\m_lxe.dll+00551351 CGGBuiltinImpl+00142263&#60;br /&#62;
[ 21] 0x00007ffb895065bf                            bin\win64\pgo\m_lxe.dll+00550335 CGGBuiltinImpl+00141247&#60;br /&#62;
[ 22] 0x00007ffb89512d65                            bin\win64\pgo\m_lxe.dll+00601445 CGGBuiltinImpl+00192357&#60;br /&#62;
[ 23] 0x00007ffb895173c5                            bin\win64\pgo\m_lxe.dll+00619461 CGGBuiltinImpl+00210373&#60;br /&#62;
[ 24] 0x00007ffb895163cc                            bin\win64\pgo\m_lxe.dll+00615372 CGGBuiltinImpl+00206284&#60;br /&#62;
[ 25] 0x00007ffb895ec163                            bin\win64\pgo\m_lxe.dll+01491299 CGGBuiltinImpl+01082211&#60;br /&#62;
[ 26] 0x00007ffb895ec04b                            bin\win64\pgo\m_lxe.dll+01491019 CGGBuiltinImpl+01081931&#60;br /&#62;
[ 27] 0x00007ffb895ebf5a                            bin\win64\pgo\m_lxe.dll+01490778 CGGBuiltinImpl+01081690&#60;br /&#62;
[ 28] 0x00007ffb89626174                            bin\win64\pgo\m_lxe.dll+01728884 MathWorks::lxe::ShutdownLxeEngine+00083620&#60;br /&#62;
[ 29] 0x00007ffb89626122                            bin\win64\pgo\m_lxe.dll+01728802 MathWorks::lxe::ShutdownLxeEngine+00083538&#60;br /&#62;
[ 30] 0x00007ffb8afd6dba                            bin\win64\pgo\m_lxe.dll+28667322 MathWorks::lxe::profiler::IMexProfilingSupport::~IMexProfilingSupport+00058926&#60;br /&#62;
[ 31] 0x00007ffb8bfdb609 C:\Program Files\MATLAB\R2020b\bin\win64\libmwbridge.dll+00177673 mnGetPrompt+00031273&#60;br /&#62;
[ 32] 0x00007ffb8c8511ff   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00463359 iqm::Iqm::instance+00001023&#60;br /&#62;
[ 33] 0x00007ffb8c8c38b7   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00932023 iqm::UserEvalPlugin::execute+00001351&#60;br /&#62;
[ 34] 0x00007ffb7feb80be C:\Program Files\MATLAB\R2020b\bin\win64\nativejmi.dll+00360638 nativejmi::JmiIIP::serializeExplicit+00013438&#60;br /&#62;
[ 35] 0x00007ffb8c877a3f   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00621119 iqm::Iqm::setupIqmFcnPtrs+00113615&#60;br /&#62;
[ 36] 0x00007ffb8c8831b0   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00668080 iqm::Iqm::setupIqmFcnPtrs+00160576&#60;br /&#62;
[ 37] 0x00007ffb8c846fc3   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00421827 iqm::Iqm::create+00007235&#60;br /&#62;
[ 38] 0x00007ffb8bfc7a3e C:\Program Files\MATLAB\R2020b\bin\win64\libmwbridge.dll+00096830 ioReadLine+00000478&#60;br /&#62;
[ 39] 0x00007ffb8bfc781c C:\Program Files\MATLAB\R2020b\bin\win64\libmwbridge.dll+00096284 ioReadLine+00000188&#60;br /&#62;
[ 40] 0x00007ffb8bfdba50 C:\Program Files\MATLAB\R2020b\bin\win64\libmwbridge.dll+00178768 mnGetCommandLineBuffer+00000304&#60;br /&#62;
[ 41] 0x00007ffb8bfdbeda C:\Program Files\MATLAB\R2020b\bin\win64\libmwbridge.dll+00179930 mnParser+00000506&#60;br /&#62;
[ 42] 0x00007ffb8c6862f4   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00549620 mcr_set_enableReadingFromStdin+00016084&#60;br /&#62;
[ 43] 0x00007ffb8c61e7ad   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00124845 mcrFunctionSignature::set_signature+00103437&#60;br /&#62;
[ 44] 0x00007ffb8c63baea   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00244458 mcrFunctionSignature::set_signature+00223050&#60;br /&#62;
[ 45] 0x00007ffb8c8a4504   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00804100 iqm::PackagedTaskPlugin::execute+00000084&#60;br /&#62;
[ 46] 0x00007ffb8c6803ce   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00525262 services::lmgr::exception::LicensingStartupException::~LicensingStartupException+00009822&#60;br /&#62;
[ 47] 0x00007ffb8c877a3f   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00621119 iqm::Iqm::setupIqmFcnPtrs+00113615&#60;br /&#62;
[ 48] 0x00007ffb8c847c42   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00425026 iqm::Iqm::create+00010434&#60;br /&#62;
[ 49] 0x00007ffb8c847421   C:\Program Files\MATLAB\R2020b\bin\win64\iqm.dll+00422945 iqm::Iqm::create+00008353&#60;br /&#62;
[ 50] 0x00007ffb8c6560dc   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00352476 mcrInstantiationError::operator=+00011756&#60;br /&#62;
[ 51] 0x00007ffb8c656a3c   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00354876 mcrInstantiationError::operator=+00014156&#60;br /&#62;
[ 52] 0x00007ffb8c6543cc   C:\Program Files\MATLAB\R2020b\bin\win64\mcr.dll+00345036 mcrInstantiationError::operator=+00004316&#60;br /&#62;
[ 53] 0x00007ffc1ff3a2a3 C:\Program Files\MATLAB\R2020b\bin\win64\mwboost_thread-vc141-mt-x64-1_70.dll+00041635 mwboost::thread::swap+00000083&#60;br /&#62;
[ 54] 0x00007ffc43466bcc                   C:\WINDOWS\System32\ucrtbase.dll+00158668 recalloc+00000092&#60;br /&#62;
[ 55] 0x00007ffc444654ee                   C:\WINDOWS\System32\KERNEL32.DLL+00087278 BaseThreadInitThunk+00000030&#60;br /&#62;
[ 56] 0x00007ffc45abc81b                      C:\WINDOWS\SYSTEM32\ntdll.dll+00509979 RtlUserThreadStart+00000043&#60;/p&#62;
&#60;p&#62;This error was detected while a MEX-file was running. If the MEX-file&#60;br /&#62;
is not an official MathWorks function, please examine its source code&#60;br /&#62;
for errors. Please consult the External Interfaces Guide for information&#60;br /&#62;
on debugging MEX-files.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>dgiraud on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8066</link>
			<pubDate>Mon, 22 Feb 2021 19:25:14 +0000</pubDate>
			<dc:creator>dgiraud</dc:creator>
			<guid isPermaLink="false">8066@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Using k-Wave 1.3 and MATLAB 2020b on Windows 10 with precompiled binaries, I was able successfully use kspaceFirstOrder3DC (within example_us_beam_patterns.m) following steps 1 and 2 of Brad's instructions. Step 3 appears unnecessary, as christianbaker noted. It looks like R2020b has been updated with the patch Brad provided; R2020b h5writeatt.m is essentially the same as the patch file.&#60;/p&#62;
&#60;p&#62;However, when trying kspaceFirstOrder3DG (again, within example_us_beam_patterns.m), the code produces an error similar to what marjanbn posted:&#60;/p&#62;
&#60;p&#62;---&#60;/p&#62;
&#60;p&#62;Error using h5readc&#60;br /&#62;
Unable to open 'C:\Users\giraud\AppData\Local\Temp\1\kwave_output_data22-Feb-2021-09-38-19.h5'. File or folder not found.&#60;/p&#62;
&#60;p&#62;Error in h5read (line 93)&#60;br /&#62;
[data,var_class] = h5readc(Filename,Dataset,start,count,stride);&#60;/p&#62;
&#60;p&#62;Error in kspaceFirstOrder3DC (line 569)&#60;br /&#62;
Nx = h5read(output_filename, '/Nx');&#60;/p&#62;
&#60;p&#62;Error in kspaceFirstOrder3DG (line 69)&#60;br /&#62;
sensor_data = kspaceFirstOrder3DC(varargin{:});&#60;/p&#62;
&#60;p&#62;Error in dg_example_us_beam_patterns (line 182)&#60;br /&#62;
sensor_data = kspaceFirstOrder3DG(kgrid, medium, transducer, sensor, input_args{:});&#60;/p&#62;
&#60;p&#62;---&#60;/p&#62;
&#60;p&#62;Is a work-around possible for this error? Looking in the k-Wave m files, I couldn't find any additional calls to h5writeatt where I could specify 'TextEncoding'.&#60;/p&#62;
&#60;p&#62;Big thank you to the k-Wave team for making this code available! I'm very grateful to be able use your work.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>marjanbn on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8057</link>
			<pubDate>Mon, 08 Feb 2021 22:53:16 +0000</pubDate>
			<dc:creator>marjanbn</dc:creator>
			<guid isPermaLink="false">8057@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hello,&#60;/p&#62;
&#60;p&#62;I am using MATLAB R2020b and I couldn't fix the problem as explained by Brad.&#60;br /&#62;
The error I am getting is&#60;/p&#62;
&#60;p&#62;----------------------------------------------&#60;br /&#62;
Error using h5readc&#60;br /&#62;
Unable to open '/tmp/kwave_output_data08-Feb-2021-16-43-56.h5'. File or folder not found.&#60;/p&#62;
&#60;p&#62;Error in h5read (line 93)&#60;br /&#62;
[data,var_class] = h5readc(Filename,Dataset,start,count,stride);&#60;/p&#62;
&#60;p&#62;Error in kspaceFirstOrder3DC (line 569)&#60;br /&#62;
Nx = h5read(output_filename, '/Nx');&#60;/p&#62;
&#60;p&#62;-----------------------------------&#60;/p&#62;
&#60;p&#62;I appreciate it if you clarify if the error I am getting is the same as in this thread and if not, how should I fix it?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Mengjie_shi on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-8027</link>
			<pubDate>Tue, 26 Jan 2021 10:33:42 +0000</pubDate>
			<dc:creator>Mengjie_shi</dc:creator>
			<guid isPermaLink="false">8027@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;I don't think 2020b has fixed the bug. I tried to update my MATLAB2020b to the latest version but still has the same error. Anyway, the solution provided by Brad works, Thank you!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7973</link>
			<pubDate>Thu, 03 Dec 2020 10:01:48 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">7973@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Thanks Christian, that's good to know!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>christianbaker on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7969</link>
			<pubDate>Mon, 30 Nov 2020 10:18:43 +0000</pubDate>
			<dc:creator>christianbaker</dc:creator>
			<guid isPermaLink="false">7969@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Just tested this in 2020b and all works fine without downloading the patched &#60;code&#62;h5writeatt&#60;/code&#62;, so it seems Mathworks have fixed the issue since 2020a.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>samantp on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7685</link>
			<pubDate>Fri, 03 Jul 2020 12:52:50 +0000</pubDate>
			<dc:creator>samantp</dc:creator>
			<guid isPermaLink="false">7685@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Ah, that seems to have resolved the issue. Thanks!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7657</link>
			<pubDate>Sat, 27 Jun 2020 13:37:01 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">7657@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi samantp,&#60;/p&#62;
&#60;p&#62;Are you using k-Wave V1.3? This function should be in the private folder, which should be accessible to writeAttributes if the root k-Wave folder is on the MATLAB path.&#60;/p&#62;
&#60;p&#62;Brad.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>samantp on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7645</link>
			<pubDate>Thu, 25 Jun 2020 15:48:21 +0000</pubDate>
			<dc:creator>samantp</dc:creator>
			<guid isPermaLink="false">7645@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi, I tried this solution but now I get the error &#34;Unrecognized function or variable 'getH5Literals'.&#60;/p&#62;
&#60;p&#62;Error in writeAttributes (line 45)&#60;br /&#62;
getH5Literals;&#60;br /&#62;
&#34;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>anubhav on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7479</link>
			<pubDate>Tue, 05 May 2020 04:09:09 +0000</pubDate>
			<dc:creator>anubhav</dc:creator>
			<guid isPermaLink="false">7479@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;That worked like a charm. Thanks a lot for the quick reply on this one and the speedups are amazing.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7477</link>
			<pubDate>Mon, 04 May 2020 16:21:55 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">7477@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Due to a change in &#60;code&#62;h5writeatt&#60;/code&#62; in MATLAB 2020a (it changed the default value of &#60;code&#62;&#38;#39;TextEncoding&#38;#39;&#60;/code&#62; from &#60;code&#62;&#38;#39;system&#38;#39;&#60;/code&#62; to &#60;code&#62;&#38;#39;UTF-8&#38;#39;&#60;/code&#62;), this version of MATLAB isn't compatible with k-Wave (any version). This doesn't affect the MATLAB-only version of k-Wave, just the functions writing HDF5 input files to use with the C++ codes.&#60;/p&#62;
&#60;p&#62;I wrote a bug-fix by adding the lines &#60;code&#62;&#38;#39;TextEncoding&#38;#39;, &#38;#39;system&#38;#39;&#60;/code&#62; to all calls to &#60;code&#62;h5writeatt&#60;/code&#62;, but then discovered a MATLAB bug in &#60;code&#62;h5writeatt&#60;/code&#62; which doesn't allow the text encoding to be changed back. After liaising with Mathworks, they confirmed this is a known issue, and helpfully sent me a patch for &#60;code&#62;h5writeatt&#60;/code&#62; which you can download &#60;a href=&#34;http://www.k-wave.org/downloads/h5writeatt.m&#34;&#62;here&#60;/a&#62;. They've given me permission to share this with k-Wave users.&#60;/p&#62;
&#60;p&#62;So in short, the work around is:&#60;/p&#62;
&#60;p&#62;1. Open &#60;code&#62;acousticFieldPropagator&#60;/code&#62;, &#60;code&#62;writeAttributes&#60;/code&#62;, and &#60;code&#62;writeMatrix&#60;/code&#62; in k-Wave.&#60;/p&#62;
&#60;p&#62;2. For all calls to &#60;code&#62;h5writeatt&#60;/code&#62;, add the option &#60;code&#62;&#38;#39;TextEncoding&#38;#39;, &#38;#39;system&#38;#39;&#60;/code&#62; to the end. For example:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;h5writeatt(save_to_disk, &#38;#39;/&#38;#39;, FILE_MAJOR_VER_ATT_NAME, FBP_FILE_MAJOR_VERSION);&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;becomes:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;h5writeatt(save_to_disk, &#38;#39;/&#38;#39;, FILE_MAJOR_VER_ATT_NAME, FBP_FILE_MAJOR_VERSION, &#38;#39;TextEncoding&#38;#39;, &#38;#39;system&#38;#39;);&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;3. Download the &#60;a href=&#34;http://www.k-wave.org/downloads/h5writeatt.m&#34;&#62;patch&#60;/a&#62; for &#60;code&#62;h5writeatt&#60;/code&#62; and either replace the version in MATLAB 2020a, or place it somewhere on the MATLAB path. You can find where &#60;code&#62;h5writeatt&#60;/code&#62; is stored by typing:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;which h5writeatt&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;It should be something like:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;C:\Program Files\MATLAB\R2020a\toolbox\matlab\imagesci\&#60;/code&#62;.&#60;/p&#62;
&#60;p&#62;Let me know any problems. I've put a link to this thread on the downloads page.&#60;/p&#62;
&#60;p&#62;Brad.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>anubhav on "Error reading h5 files when using binaries (MATLAB 2020a)"</title>
			<link>http://www.k-wave.org/forum/topic/error-reading-h5-files-when-using-binaries#post-7472</link>
			<pubDate>Sun, 03 May 2020 23:43:24 +0000</pubDate>
			<dc:creator>anubhav</dc:creator>
			<guid isPermaLink="false">7472@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;I have tried this with downloading the executables provided and by compiling from source but it seems like when using the C++ and GPU binaries there is an issue in reading the h5 files.&#60;/p&#62;
&#60;p&#62;Here is the error I get&#60;br /&#62;
./kspaceFirstOrder-CUDA -i /tmp/example_input.h5 -o /tmp/example_output.h5 --p_final --p_max --verbose 2&#60;/p&#62;
&#60;p&#62;┌───────────────────────────────────────────────────────────────┐&#60;br /&#62;
│                  kspaceFirstOrder-CUDA v1.3                   │&#60;br /&#62;
├───────────────────────────────────────────────────────────────┤&#60;br /&#62;
│ Git hash:            468dc31c2842a7df5f2a07c3a13c16c9b0b2b770 │&#60;br /&#62;
├───────────────────────────────────────────────────────────────┤&#60;br /&#62;
│ Reading simulation configuration:                      Failed │&#60;br /&#62;
└───────────────────────────────────────────────────────────────┘&#60;br /&#62;
┌───────────────────────────────────────────────────────────────┐&#60;br /&#62;
│            !!! K-Wave experienced a fatal error !!!           │&#60;br /&#62;
├───────────────────────────────────────────────────────────────┤&#60;br /&#62;
│ Error: Invalid format of the input file: iostream error       │&#60;br /&#62;
├───────────────────────────────────────────────────────────────┤&#60;br /&#62;
│                      Execution terminated                     │&#60;br /&#62;
└───────────────────────────────────────────────────────────────┘&#60;/p&#62;
&#60;p&#62;My findings and process:&#60;/p&#62;
&#60;p&#62;I am comiling from source using hdf5 v1.8.12 ( this seems to be the same version used by Matlab R2020a to write the file) &#60;/p&#62;
&#60;p&#62;&#38;gt;&#38;gt; a = hdf5info('/tmp/example_input.h5')&#60;/p&#62;
&#60;p&#62;a = &#60;/p&#62;
&#60;p&#62;  struct with fields:&#60;/p&#62;
&#60;p&#62;          Filename: 'example_input.h5'&#60;br /&#62;
        LibVersion: '1.8.12'&#60;br /&#62;
            Offset: 0&#60;br /&#62;
          FileSize: 42880070&#60;br /&#62;
    GroupHierarchy: [1×1 struct]&#60;/p&#62;
&#60;p&#62;On digging deeper into and doing console logs in the Hdf5/Hdf5File.cpp library to see the values of attributes fetched, it looks like there is an issue when attempting to read it.&#60;/p&#62;
&#60;p&#62;string Hdf5File::readStringAttribute&#60;/p&#62;
&#60;p&#62;Added : std::cout &#38;lt;&#38;lt; &#34; ****** readStringAttr ******* &#34; &#38;lt;&#38;lt; attributeName.c_str() &#38;lt;&#38;lt; &#34; ::: &#34; &#38;lt;&#38;lt; string(value) &#38;lt;&#38;lt; &#34;\n&#34;;&#60;/p&#62;
&#60;p&#62;Output :  ****** readStringAttr ******* file_type ::: ��&#60;/p&#62;
&#60;p&#62;Please let me know how to resolve this error and I can use the CUDA library for optimizing the simulations
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
