<?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: cudaMemcpy error</title>
		<link>http://www.k-wave.org/forum/topic/cudamemcpy-error</link>
		<description>Support for the k-Wave MATLAB toolbox</description>
		<language>en-US</language>
		<pubDate>Tue, 12 May 2026 22:28:44 +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/cudamemcpy-error" rel="self" type="application/rss+xml" />

		<item>
			<title>Eric Miller on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7924</link>
			<pubDate>Tue, 17 Nov 2020 21:43:19 +0000</pubDate>
			<dc:creator>Eric Miller</dc:creator>
			<guid isPermaLink="false">7924@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi Jiri,&#60;/p&#62;
&#60;p&#62;I'm now working on this code with ArikHananel and jlc4kk, has there been any more investigation into this?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jlc4kk on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7473</link>
			<pubDate>Mon, 04 May 2020 04:26:03 +0000</pubDate>
			<dc:creator>jlc4kk</dc:creator>
			<guid isPermaLink="false">7473@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Yes we can share with you a script of our example. I sent it to your fit email. Thank you for your help!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Jiri Jaros on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7441</link>
			<pubDate>Mon, 27 Apr 2020 12:26:20 +0000</pubDate>
			<dc:creator>Jiri Jaros</dc:creator>
			<guid isPermaLink="false">7441@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi ArikHananel,&#60;br /&#62;
It might be a covered out-of-memory error (but might not be the case since it run on older GPUs). Would it be possible to share an input file (or a matlab script to generate it) for this simulation with me? What kind of source do you use?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>ArikHananel on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7421</link>
			<pubDate>Sun, 19 Apr 2020 23:18:04 +0000</pubDate>
			<dc:creator>ArikHananel</dc:creator>
			<guid isPermaLink="false">7421@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;I updated to 1.3 and put the pre-compiled binaries in the k-wave binaries folder and checked the version and got:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;+---------------------------------------------------------------+
&#124;                  kspaceFirstOrder-CUDA v1.3                   &#124;
+---------------------------------------------------------------+
&#124; Selected GPU device id:                                     0 &#124;
&#124; GPU device name:                                    TITAN RTX &#124;
+---------------------------------------------------------------+
&#124;                       Build information                       &#124;
+---------------------------------------------------------------+
&#124; Build number:     kspaceFirstOrder v3.6                       &#124;
&#124; Build date:       Feb 26 2020                                 &#124;
&#124; Build time:       18:12:32                                    &#124;
&#124; Git hash:         468dc31c2842a7df5f2a07c3a13c16c9b0b2b770    &#124;
+---------------------------------------------------------------+
&#124; Operating system: Windows x64                                 &#124;
&#124; Compiler name:    Visual Studio C++ 1916                      &#124;
&#124; Processor name:   Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz     &#124;
&#124; Instruction set:  Intel AVX                                   &#124;
+---------------------------------------------------------------+
&#124; CUDA runtime:     10.2                                        &#124;
&#124; CUDA driver:      10.2                                        &#124;
&#124; CUDA code arch:   7.5                                         &#124;
+---------------------------------------------------------------+
&#124; CUDA device id:   0                                           &#124;
&#124; CUDA device name: TITAN RTX                                   &#124;
&#124; CUDA capability:  7.5                                         &#124;
+---------------------------------------------------------------+
&#124; Contact email:    &#60;a href=&#34;mailto:jarosjir@fit.vutbr.cz&#34;&#62;jarosjir@fit.vutbr.cz&#60;/a&#62;                       &#124;
&#124; Contact web:      &#60;a href=&#34;http://www.k-wave.org&#34; rel=&#34;nofollow&#34;&#62;http://www.k-wave.org&#60;/a&#62;                       &#124;
+---------------------------------------------------------------+
&#124; Copyright (C) 2011-2020 SC@FIT Research Group, BUT, Czech Rep &#124;
+---------------------------------------------------------------+&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;but I am getting a same error:&#60;/p&#62;
&#60;p&#62;Running k-Wave simulation...&#60;br /&#62;
  start time: 19-Apr-2020 18:04:43&#60;br /&#62;
  reference sound speed: 2820m/s&#60;br /&#62;
  dt: 7.3052ns, t_end: 397.6583us, time steps: 54436&#60;br /&#62;
  input grid size: 412 by 236 by 236 grid points (154.5 by 88.5 by 88.5mm)&#60;br /&#62;
  maximum supported frequency: 2.1067MHz&#60;br /&#62;
  expanding computational grid...&#60;br /&#62;
  computational grid size: 432 by 256 by 256 grid points&#60;br /&#62;
  precomputation completed in 1min 10.6293s&#60;br /&#62;
  saving input files to disk...&#60;br /&#62;
  completed in 2min 13.8809s&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;+---------------------------------------------------------------+
&#124;                  kspaceFirstOrder-CUDA v1.3                   &#124;
+---------------------------------------------------------------+
&#124; Reading simulation configuration:                        Done &#124;
&#124; Selected GPU device id:                                     0 &#124;
&#124; GPU device name:                                    TITAN RTX &#124;
&#124; Number of CPU threads:                                      1 &#124;
&#124; Processor name:       Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz &#124;
+---------------------------------------------------------------+
&#124;                      Simulation details                       &#124;
+---------------------------------------------------------------+
&#124; Domain dimensions:                            432 x 256 x 256 &#124;
&#124; Medium type:                                               3D &#124;
&#124; Simulation time steps:                                  54436 &#124;
+---------------------------------------------------------------+
&#124;                        Initialization                         &#124;
+---------------------------------------------------------------+
&#124; Memory allocation:                                       Done &#124;
&#124; Data loading:                                            Done &#124;
&#124; Elapsed time:                                           2.90s &#124;
+---------------------------------------------------------------+
&#124; FFT plans creation:                                      Done &#124;
&#124; Pre-processing phase:                                    Done &#124;
&#124; Elapsed time:                                           2.98s &#124;
+---------------------------------------------------------------+
&#124;                    Computational resources                    &#124;
+---------------------------------------------------------------+
&#124; Current host memory in use:                           10177MB &#124;
&#124; Current device memory in use:                         14421MB &#124;
&#124; Expected output file size:                              175MB &#124;
+---------------------------------------------------------------+
&#124;                          Simulation                           &#124;
+----------+----------------+--------------+--------------------+
&#124; Progress &#124;  Elapsed time  &#124;  Time to go  &#124;  Est. finish time  &#124;
+----------+----------------+--------------+--------------------+
+----------+----------------+--------------+--------------------+
+---------------------------------------------------------------+
&#124;            !!! K-Wave experienced a fatal error !!!           &#124;
+---------------------------------------------------------------+
&#124; GPU error: unspecified launch failure routine name:           &#124;
&#124;        cudaMemcpy(mDeviceData, mHostData, mCapacity * sizeof( &#124;
&#124;        float), cudaMemcpyHostToDevice) in file d:\windows     &#124;
&#124;        source\k-wave-fluid-cuda\sources\matrixclasses\        &#124;
&#124;        basefloatmatrix.cpp, line 99.                          &#124;
+---------------------------------------------------------------+
&#124;                      Execution terminated                     &#124;
+---------------------------------------------------------------+&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Error using h5readc&#60;br /&#62;
The HDF5 library encountered an error and produced the following stack trace information:&#60;/p&#62;
&#60;p&#62;    H5G_loc_find_cb      object 'Nx' doesn't exist&#60;br /&#62;
    H5G_traverse_real    traversal operator failed&#60;br /&#62;
    H5G_traverse         internal path traversal failed&#60;br /&#62;
    H5G_loc_find         can't find object&#60;br /&#62;
    H5Dopen2             not found&#60;/p&#62;
&#60;p&#62;Error in h5read (line 58)&#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;</description>
		</item>
		<item>
			<title>Jiri Jaros on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7395</link>
			<pubDate>Tue, 14 Apr 2020 11:42:46 +0000</pubDate>
			<dc:creator>Jiri Jaros</dc:creator>
			<guid isPermaLink="false">7395@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Yep, the CUDA runtime is too old for TITAN RTX (By the time we compiled that code, TITAN RTX did not exist and naturally couldn't be supported). You need  k-Wave V1.3, as Brad suggested, or recompile the code with newer CUDA and include RTX SM architecture in the makefile.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7388</link>
			<pubDate>Mon, 13 Apr 2020 07:35:55 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">7388@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Can you try with k-Wave V1.3? That should resolve the problem.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jlc4kk on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7387</link>
			<pubDate>Mon, 13 Apr 2020 06:58:45 +0000</pubDate>
			<dc:creator>jlc4kk</dc:creator>
			<guid isPermaLink="false">7387@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Here is the output:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;+---------------------------------------------------------------+
&#124;                 kspaceFirstOrder3D-CUDA v1.2                  &#124;
+---------------------------------------------------------------+
&#124; Selected GPU device id:                                     0 &#124;
&#124; GPU device name:                                    TITAN RTX &#124;
+---------------------------------------------------------------+
&#124;                       Build information                       &#124;
+---------------------------------------------------------------+
&#124; Build number:     kspaceFirstOrder3D v3.5                     &#124;
&#124; Build date:       Sep  4 2017                                 &#124;
&#124; Build time:       22:06:54                                    &#124;
&#124; Git hash:         992307ffbd4711af502c9be35a1eacfdbc756887    &#124;
+---------------------------------------------------------------+
&#124; Operating system: Windows x64                                 &#124;
&#124; Compiler name:    Visual Studio C++ 1900                      &#124;
+---------------------------------------------------------------+
&#124; CUDA runtime:     8.0                                         &#124;
&#124; CUDA driver:      10.2                                         &#124;
&#124; CUDA code arch:   6.1                                         &#124;
+---------------------------------------------------------------+
&#124; CUDA device id:   0                                           &#124;
&#124; CUDA device name: TITAN RTX                                   &#124;
&#124; CUDA capability:  7.5                                         &#124;
+---------------------------------------------------------------+
&#124; Contact email:    &#60;a href=&#34;mailto:jarosjir@fit.vutbr.cz&#34;&#62;jarosjir@fit.vutbr.cz&#60;/a&#62;                       &#124;
&#124; Contact web:      &#60;a href=&#34;http://www.k-wave.org&#34; rel=&#34;nofollow&#34;&#62;http://www.k-wave.org&#60;/a&#62;                       &#124;
+---------------------------------------------------------------+
&#124;       Copyright (C) 2017 Jiri Jaros and Bradley Treeby        &#124;
+---------------------------------------------------------------+&#60;/code&#62;&#60;/pre&#62;</description>
		</item>
		<item>
			<title>Jiri Jaros on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7185</link>
			<pubDate>Tue, 21 Jan 2020 08:40:39 +0000</pubDate>
			<dc:creator>Jiri Jaros</dc:creator>
			<guid isPermaLink="false">7185@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi jlc4kk,&#60;br /&#62;
I suspect the code was not compiled for RTX GPUs. Could you please run this command to see what happens?&#60;/p&#62;
&#60;p&#62;./kspaceFirstOrder3D-CUDA --version
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jlc4kk on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7122</link>
			<pubDate>Tue, 12 Nov 2019 07:02:07 +0000</pubDate>
			<dc:creator>jlc4kk</dc:creator>
			<guid isPermaLink="false">7122@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Forgot to add that I am using k-Wave 1.2.1
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jlc4kk on "cudaMemcpy error"</title>
			<link>http://www.k-wave.org/forum/topic/cudamemcpy-error#post-7120</link>
			<pubDate>Sun, 10 Nov 2019 23:09:22 +0000</pubDate>
			<dc:creator>jlc4kk</dc:creator>
			<guid isPermaLink="false">7120@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;I recently upgrade by GPU from a Titan XP 12 Gb to a Titan RTX 24 Gb and simulations that were able to run on the older GPU seem to be having issues with the new GPU. Here is the message output from MATLAB:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;Running k-Wave simulation...
  start time: 10-Nov-2019 15:52:42
  reference sound speed: 2820m/s
  dt: 7.3052ns, t_end: 397.6583us, time steps: 54436
  input grid size: 412 by 236 by 236 grid points (154.5 by 88.5 by 88.5mm)
  maximum supported frequency: 2.1067MHz
  expanding computational grid...
  computational grid size: 432 by 256 by 256 grid points
  precomputation completed in 51.1248s
  saving input files to disk...
  completed in 51.1804s
+---------------------------------------------------------------+
&#124;                 kspaceFirstOrder3D-CUDA v1.2                  &#124;
+---------------------------------------------------------------+
&#124; Reading simulation configuration:                        Done &#124;
&#124; Selected GPU device id:                                     0 &#124;
&#124; GPU device name:                                    TITAN RTX &#124;
&#124; Number of CPU threads:                                      1 &#124;
+---------------------------------------------------------------+
&#124;                      Simulation details                       &#124;
+---------------------------------------------------------------+
&#124; Domain dimensions:                            432 x 256 x 256 &#124;
&#124; Simulation time steps:                                  54436 &#124;
+---------------------------------------------------------------+
&#124;                        Initialization                         &#124;
+---------------------------------------------------------------+
&#124; Memory allocation:                                       Done &#124;
&#124; Data loading:                                            Done &#124;
&#124; Elapsed time:                                           2.49s &#124;
+---------------------------------------------------------------+
&#124; FFT plans creation:                                      Done &#124;
&#124; Pre-processing phase:                                    Done &#124;
&#124; Elapsed time:                                           3.47s &#124;
+---------------------------------------------------------------+
&#124;                    Computational resources                    &#124;
+---------------------------------------------------------------+
&#124; Current host memory in use:                            9858MB &#124;
&#124; Current device memory in use:                         13971MB &#124;
+---------------------------------------------------------------+
&#124;                          Simulation                           &#124;
+----------+----------------+--------------+--------------------+
&#124; Progress &#124;  Elapsed time  &#124;  Time to go  &#124;  Est. finish time  &#124;
+----------+----------------+--------------+--------------------+
+----------+----------------+--------------+--------------------+
+---------------------------------------------------------------+
&#124;            !!! K-Wave experienced a fatal error !!!           &#124;
+---------------------------------------------------------------+
&#124; GPU error: unspecified launch failure routine name:           &#124;
&#124;        cudaMemcpy(mDeviceData, mHostData, mCapacity * sizeof( &#124;
&#124;        float), cudaMemcpyHostToDevice) in file MatrixClasses\ &#124;
&#124;        BaseFloatMatrix.cpp, line 99.                          &#124;
+---------------------------------------------------------------+
&#124;                      Execution terminated                     &#124;
+---------------------------------------------------------------+
Error using h5readc
The HDF5 library encountered an error and produced the following stack trace information:

    H5G_loc_find_cb      object &#38;#39;Nx&#38;#39; doesn&#38;#39;t exist
    H5G_traverse_real    traversal operator failed
    H5G_traverse         internal path traversal failed
    H5G_loc_find         can&#38;#39;t find object
    H5Dopen2             not found

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

Error in kspaceFirstOrder3DC (line 394)
Nx = h5read(output_filename, &#38;#39;/Nx&#38;#39;);

Error in kspaceFirstOrder3DG (line 64)
    sensor_data = kspaceFirstOrder3DC(varargin{:}, &#38;#39;BinaryName&#38;#39;, binary_name);

Error in acousticSimulationAllRings (line 127)
sensor_data = kspaceFirstOrder3DG(kgrid, medium, source, sensor, input_args{:});

Error in runAcoustic (line 11)
acousticSimulationAllRings&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;My nvidia driver version is 26.21.14.4097&#60;br /&#62;
GPU: Titan RTX 24 Gb&#60;br /&#62;
OS: Windows 10 Home&#60;br /&#62;
32 Gb RAM&#60;/p&#62;
&#60;p&#62;Do you have any guidance on resolving this issue?&#60;/p&#62;
&#60;p&#62;Thank you.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
