<?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: Subsampling the recorded pressure field in time</title>
		<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time</link>
		<description>Support for the k-Wave MATLAB toolbox</description>
		<language>en-US</language>
		<pubDate>Tue, 12 May 2026 23:02:11 +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/subsampling-the-recorded-pressure-field-in-time" rel="self" type="application/rss+xml" />

		<item>
			<title>Jiri Jaros on "Subsampling the recorded pressure field in time"</title>
			<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time#post-6876</link>
			<pubDate>Fri, 07 Jun 2019 12:44:13 +0000</pubDate>
			<dc:creator>Jiri Jaros</dc:creator>
			<guid isPermaLink="false">6876@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi laughingrice,&#60;/p&#62;
&#60;p&#62;first of all you can use the parameter -s to start sampling at a timestep you need (not the whole timespan of the simulation).&#60;/p&#62;
&#60;p&#62;second, there's no decimation in the C++/CUDA code, however, it should not be so difficult to implement it by our own if you know a little bit about C++. If so, you can open KSpaceFirstOrder3DSolver.cpp  and find a routine storeSensorData(). Now, if you want to sample every other timestep, just add a modulo operation here. The other change will be in IndexOutputStream::create() or CuboidOtputStream and you change the number of timesteps  at this line&#60;/p&#62;
&#60;p&#62;  // Derive dataset dimension sizes&#60;br /&#62;
  DimensionSizes datasetSize(nSampledElementsPerStep,&#60;br /&#62;
                             (mReduceOp == ReduceOperator::kNone) ?&#60;br /&#62;
                               params.getNt() - params.getSamplingStartTimeIndex() : 1,&#60;br /&#62;
                             1);&#60;/p&#62;
&#60;p&#62;You you want to do averaging over multiple time steps, you would have to reimplement the sample() method.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>laughingrice on "Subsampling the recorded pressure field in time"</title>
			<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time#post-6845</link>
			<pubDate>Thu, 09 May 2019 19:23:52 +0000</pubDate>
			<dc:creator>laughingrice</dc:creator>
			<guid isPermaLink="false">6845@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Also, you mention having to use the MATLAB interface, I'm running simulations in 2D right now, I don't believe that there is a non-matlab interface to that
&#60;/p&#62;</description>
		</item>
		<item>
			<title>laughingrice on "Subsampling the recorded pressure field in time"</title>
			<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time#post-6844</link>
			<pubDate>Thu, 09 May 2019 15:11:27 +0000</pubDate>
			<dc:creator>laughingrice</dc:creator>
			<guid isPermaLink="false">6844@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Thanks Brad&#60;/p&#62;
&#60;p&#62;I am using CUDA so it will help a bit, but things are borderline in CPU memory as well (I'm still looking at around 40GB). Where are things processed inside the k-wave code? Wondering it it's easy enough to just decimate by a factor of two with no filtering (i.e save every second step). It usually works well enough for RTM imaging.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "Subsampling the recorded pressure field in time"</title>
			<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time#post-6843</link>
			<pubDate>Wed, 08 May 2019 21:31:57 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">6843@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Are you using the native CUDA code? This should stream the data from the GPU memory by default. There’s also the ‘StreamToDisk’ optional input if for some reason you need to use the MATLAB version.&#60;/p&#62;
&#60;p&#62;Unfortunately there’s currently  no way to decimate the data, although it is on the development list.&#60;/p&#62;
&#60;p&#62;Brad
&#60;/p&#62;</description>
		</item>
		<item>
			<title>laughingrice on "Subsampling the recorded pressure field in time"</title>
			<link>http://www.k-wave.org/forum/topic/subsampling-the-recorded-pressure-field-in-time#post-6842</link>
			<pubDate>Wed, 08 May 2019 21:25:00 +0000</pubDate>
			<dc:creator>laughingrice</dc:creator>
			<guid isPermaLink="false">6842@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;When setting sensor.record = {'p'} to record the pressure field at given grid positions, is it possible to subsample the recorded data in time? (preferably with a FIR decimation filter applied)&#60;/p&#62;
&#60;p&#62;I need to record the time dependent pressure field solution over most of the domain, but doing that at the full time resolution is both not needed (the nyquist frequency is significantly lower than the simulation frequency) and impossible due to memory requirements (about 48GB on a 10GB GPU).&#60;/p&#62;
&#60;p&#62;I couldn't find any way to do that in the documentation. I also tried to figure out if there is a way to checkpoint the simulation to offload data, but that doesn't seem possible either.&#60;/p&#62;
&#60;p&#62;Thanks
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
