# Fast Filtered Noise Demo

**URL:** <https://psychtoolbox.discourse.group/t/fast-filtered-noise-demo/668>\
**Category:** Uncategorized\
**Created:** [January 23, 2007, 7:27pm UTC](https://psychtoolbox.discourse.group/t/fast-filtered-noise-demo/668 "2007-01-23T19:27:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Peter\_54971](https://avatars.discourse-cdn.com/v4/letter/p/f9ae1b/32.png) [@Peter\_54971](https://psychtoolbox.discourse.group/u/Peter_54971)\
**Post date:** [January 23, 2007, 7:27pm UTC](https://psychtoolbox.discourse.group/t/fast-filtered-noise-demo/668/1 "2007-01-23T19:27:58Z")

</div>

Hi,  
  
I have two questions regarding the Fast Filtered Noise Demo:  
1) It seems to rely on access to one or more of Matlab's Image toolboxes. Is that true? If so,   
is there a way to run the demonstration if one doesn't have the related toolbox(es) resident?  
  
And...since a colleague runs Psychtoolbox on a pc:  
  
2) Is there a version of the fast filtered noise demonstration available for use on a windows   
machine?  
  
Thanks much,  
Tim Petersik

---

<div class="post-metadata">

**Author:** ![mariokleiner](https://avatars.discourse-cdn.com/v4/letter/m/13edae/32.png) [@mariokleiner](https://psychtoolbox.discourse.group/u/mariokleiner)\
**Post date:** [January 24, 2007, 4:00pm UTC](https://psychtoolbox.discourse.group/t/fast-filtered-noise-demo/668/2 "2007-01-24T16:00:57Z")

</div>

Oops. I think FastFilteredNoiseDemo slipped into the beta too early. I  
use it to test and fine tune convolution filtering on the  
gfx-hardware. Not sure if this already useful for you, this will  
change significantly before it is officially ready.  
  
Currently it uses functions from the image processing toolbox, but  
they could be easily replaced by self written code:  
  
a. fspecial generates simple 2D convolution kernels for gaussians,  
laplace operators, sobels and such. Its output is just a small n x n  
Matlab matrix filled with the proper filter weights, easy to create  
yourself for a specific kernel.  
  
b. In the workloop it uses image processing toolbox functions for 2D  
convolution: The script performs filtering once on the GPU, then with  
Matlab, then compares both results and plots an error surface, mean  
and maximum error. Its meant to verify correctness of the GPU  
implementation, assuming that Matlab does the right thing.  
  
Obviously you could write both on your own and get rid of b) in  
practical application.  
  
  
The demo itself is operating system independent and verified to work  
on WinXP+Nvidia GF7800 and MacBookPro+OSX, but gfx-hardware dependent.   
  
GPU image processing needs recent graphics hardware to work at all or  
at a high speed, the more recent the better. With high end hw the  
speedup can be anywhere from 25 - 100 compared to a high end PC, the   
mid-level gfx MBP yields about 3-10 fold speedup compared to the intel  
core duo matlab solution.  
  
Stay tuned...  
-mario  
  

> --- In [psychtoolbox@yahoogroups.com](mailto:psychtoolbox@yahoogroups.com), "Peter\_54971" \<PetersikT@...\> wrote:  
> \>  
> \> Hi,  
> \>   
> \> I have two questions regarding the Fast Filtered Noise Demo:  
> \> 1) It seems to rely on access to one or more of Matlab's Image  
> toolboxes. Is that true? If so,   
> \> is there a way to run the demonstration if one doesn't have the  
> related toolbox(es) resident?  
> \>   
> \> And...since a colleague runs Psychtoolbox on a pc:  
> \>   
> \> 2) Is there a version of the fast filtered noise demonstration  
> available for use on a windows   
> \> machine?  
> \>   
> \> Thanks much,  
> \> Tim Petersik  
> \>
