Room Acoustics Simulation Using GPU
-
Upload
chirag-batra -
Category
Engineering
-
view
23 -
download
6
Transcript of Room Acoustics Simulation Using GPU
![Page 1: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/1.jpg)
ROOM ACOUSTICS SIMULATION USING GRAPHICS PROCESSING UNIT
GROUP ID:16PROJECT GUIDE: Prof. Sumeet Harale
Presented By:Chirag Batra
![Page 2: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/2.jpg)
Outlines• What is Room Acoustics• First Order Reflection and Diffusion• Problem Statement• Goals and Objectives• Purpose of Room Acoustics• Introduction to CUDA• Why Room Acoustics Simulation with CUDA• Introduction to GPU• Difference between CPU and GPU• Methods To Implement Room Acoustics Simulation• TLM(Transmission Line Matrix)• Conclusion
![Page 3: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/3.jpg)
What is
Room Acoustic
![Page 4: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/4.jpg)
• The way to describe how sound propagates in a room• It will react differently to different frequencies of sound when it
strikes to different objects
Figure(1):3d Acoustics in a closed room
![Page 5: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/5.jpg)
First Order Reflection• The first locations where sound reflects between
our ears and the speakers
Diffusion• net movement of molecules• from a region of high concentration to a region
of low concentration
![Page 6: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/6.jpg)
Room Acoustic SimulationFor what purpose?
• In video game…• So that we can have the acoustic spatial perception
• For hearing the simulated sound given the room map
• Used in Aerospace laboratory to calculate noise produced by Aero plane
![Page 7: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/7.jpg)
Problem Statement
• To Show The Simulation of a Sound Wave propagating in a room and to implement TLM for Room Acoustic Simulation.
![Page 8: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/8.jpg)
Goals • To explain & implement how sound wave propagation is modelled in a room using
GPU
Objectives • To Learn OPENGL • To learn CUDA Programming • To Understand Acoustics Simulation
![Page 9: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/9.jpg)
Introduction To CUDA
• CUDA is a parallel computing platform and application programming interface (API) model created by NVIDIA.• Allows software developers to use a CUDA-enabled GPU for general purpose
processing – known as GPGPU.
![Page 10: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/10.jpg)
Room Acoustic Simulation why with CUDA
• Simulation of propagation because the pressure of each spatial point can be parallel computed•DCT(Discrete cosine transform) implementation
based on cuFFT(CUDA Fast Fourier Transform)
![Page 11: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/11.jpg)
What is GPU?
• GPU-accelerated computing is the use of a GPU together with a CPU to accelerate scientific, analytics, engineering, consumer, and enterprise applications. • Used in power energy-efficient datacenters in government labs, universities,
enterprises, and small-and-medium businesses around the world.
![Page 12: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/12.jpg)
Figure(5):GPU Acceleration
![Page 13: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/13.jpg)
Difference between CPU and GPU • CPU is the brain of the computer the GPU is only meant to complement it.• GPUs are specialized and cannot replace the function of a CPU.• CPUs can perform the functions of a GPU but at a much slower speed.• GPUs can rival CPUs in transistor count.• GPUs can also work in tandem just like the CPU’s multi core capability.
![Page 14: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/14.jpg)
Implementation of Room Acoustics Simulation
![Page 15: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/15.jpg)
Transmission Line Matrix
• Space and time discretizing method• Computation of electromagnetic fields• Based on the analogy between the electromagnetic field and a
mesh of transmission lines• Allows the computation of complex three-dimensional
electromagnetic structures• Is a numerical method used to simulate wave propagation
![Page 16: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/16.jpg)
Transmission Line Matrix Implementation
• Based on Huygens Principle, “Each point on a wave front acts as a source of secondary wavelets At a later time, the envelope of the leading edges of the wavelets forms the new wave front”• Implementation of the grid of nodes , wave propagation was made in C++ and OpenGL• Application is divided into several classes• Each node is represented on the screen as a two by two pixel square that has a color
that depends on the amount of pressure currently present in the node• Each node, two vectors, represent the flow of pressure between the nodes.• One incoming pressure one outgoing• The program uses the TLM methods to distribute all the pressure to the neighboring
nodes.
![Page 17: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/17.jpg)
Transmission Line Matrix Implementation
• A sinusoidal source , at a node in the room, adding pressure to the incoming vector of this node at each time instant.
• Without a source of some kind there is no pressure to be scattered between the nodes.
• Virtual Microphones used for pressure detection
![Page 18: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/18.jpg)
Kernel Code• Function callable from Host and executed on CUDA device• Simultaneously by threads in parallel• In this project we have used “kernel.cuh” to process CUDA • To call a kernel involves specifying the name of the kernel plus an execution
configuration• Thread allocated by kernel is equal to number of nodes in a block
![Page 19: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/19.jpg)
Working of TLM
A source is added
Scattering of node
Simulation and result
Room
Source
Simulation
![Page 20: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/20.jpg)
GPU vs CPUPressure on Nodes CPU(time in seconds if
number of nodes simulated are same)
GPU(time in seconds if number of nodes simulated are same)
0.454649 2 0.1
0.309246 4 0.2
0.0334211 6 0.3
0.49468 8 0.4
0.305479 10 0.5
![Page 21: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/21.jpg)
Result
Comparison of CPU and GPU Performance
![Page 22: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/22.jpg)
Software Requirements• Visual Studio 13.0• C/C++ Toolkit• OpenGL Libraries• CUDA Toolkit
![Page 23: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/23.jpg)
Conclusion
• The programmability, processing and execution speed of GPU is faster as compared to CPU.• GPU is not only used for graphics related problems but also for
General Purpose problems(GPGPU) like Room Acoustics Simulation.• TLM is the efficient method used for Room Acoustics Simulation.
![Page 24: Room Acoustics Simulation Using GPU](https://reader035.fdocuments.in/reader035/viewer/2022062900/58ee88a31a28abd77b8b4637/html5/thumbnails/24.jpg)
THANK YOU