Chapter 3 Interacting with Distributed Arrays Chung-Wei Chen, Department of Mathematics, National Taiwan University 2011/10/28.

Slides:



Advertisements
Similar presentations
Flow Charts, Loop Structures
Advertisements

Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Compiler Challenges for High Performance Architectures
REAL-TIME INDEPENDENT COMPONENT ANALYSIS IMPLEMENTATION AND APPLICATIONS By MARCOS DE AZAMBUJA TURQUETI FERMILAB May RTC 2010.
General Computer Science for Engineers CISC 106 Lecture 21 Dr. John Cavazos Computer and Information Sciences 04/10/2009.
Program Flow Charting How to tackle the beginning stage a program design.
ENGR 101: Robotics Lecture 2 – Text Programming Outline  Introduction to PBASIC  Variables, I/O, Arithmetic  Controlling the LEDs References 
Program Flow Charting How to tackle the beginning stage a program design.
M. apollonioCM18, RAL - UK - 13/06/20071 Diffuser Control Logic Marco Apollonio, Univ. of Oxford.
Parallelizing Compilers Presented by Yiwei Zhang.
Cliff Rhyne and Jerry Fu June 5, 2007 Parallel Image Segmenter CSE 262 Spring 2007 Project Final Presentation.
A Design Method for MIMO Radar Frequency Hopping Codes Chun-Yang Chen and P. P. Vaidyanathan California Institute of Technology Electrical Engineering/DSP.
Chapter 3 Planning Your Solution
Lecture Notes 8/30/05 Program Design & Intro to Algorithms.
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Unit 1. Sorting and Divide and Conquer. Lecture 1 Introduction to Algorithm and Sorting.
DCT 1123 PROBLEM SOLVING & ALGORITHMS INTRODUCTION TO PROGRAMMING.
1 Fast and selection algorithms with application to median filtering Instructor : T.-Y. Liang Reporter : Shiuh-Pyng Yang.
Lecture 1: Introduction Lecture series based on the text: Essential MATLAB for Engineers and Scientists By Hahn & Valentine
1 Quiz Preparation l Quiz 4 sheet provided. l Fill in your Name, etc. l Date is 9/11/12 l Answer questions during lecture. Lab Day/TimeSection Number Mon.
1 Chapter 1 MATLAB Primer This introductory chapter is relatively short and has as its main objective the introduction of MATLAB ® to the reader. This.
ECE 8443 – Pattern Recognition ECE 8423 – Adaptive Signal Processing Objectives: Introduction SNR Gain Patterns Beam Steering Shading Resources: Wiki:
Chapter 1 What is Programming? Lecture Slides to Accompany An Introduction to Computer Science Using Java (2nd Edition) by S.N. Kamin, D. Mickunas, E.
© Cambridge University Press 2013 Thomson_alphaem.
© Cambridge University Press 2013 Thomson_Fig
IXA 1234 : C++ PROGRAMMING CHAPTER 1. PROGRAMMING LANGUAGE Programming language is a computer program that can solve certain problem / task Keyword: Computer.
Physics Based Formation Behavior in Autonomous Robots Mark Patterson.
Chapter 3 MATLAB Fundamentals Introduction to MATLAB Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Programming at a high level. Developing a Computer Program Programmer  Writes program in source code (VB or other language) Compiler  Converts source.
Introduction to MATLAB 7 MATLAB Programming for Engineer Hassan Migdadi Spring 2013.
Introduction to Video Game Programming (VGP) Mr. Shultz.
Department of Mechanical Engineering, LSUSession VII MATLAB Tutorials Session VII Introduction to SIMULINK Rajeev Madazhy
M Machine Learning F# and Accord.net.
Slide-1 Parallel Matlab MIT Lincoln Laboratory Parallel Programming in Matlab -Tutorial- Jeremy Kepner, Albert Reuther and Hahn Kim MIT Lincoln Laboratory.
Slide-1 Multicore Theory MIT Lincoln Laboratory Theory of Multicore Algorithms Jeremy Kepner and Nadya Bliss MIT Lincoln Laboratory HPEC 2008 This work.
Introduction to MATLAB 7 Engineering 161 Engineering Practices II Joe Mixsell Spring 2012.
Introduction to Testing CSIS 1595: Fundamentals of Programming and Problem Solving 1.
Slide-1 Parallel MATLAB MIT Lincoln Laboratory Multicore Programming in pMatlab using Distributed Arrays Jeremy Kepner MIT Lincoln Laboratory This work.
Arxterra Telemetry Code Example is the Temperature Sensor from ATechTop Here is the setup subroutine of the original code from Sparkfun: #define TRUE 1.
MapReduce Basics Chapter 2 Lin and Dyer & /tutorial/
Introduction to Programming on MATLAB Ecological Modeling Course Sep 11th, 2006.
Secure Execution of Computations in Untrusted Hosts S. H. K. Narayanan 1, M.T. Kandemir 1, R.R. Brooks 2 and I. Kolcu 3 1 Embedded Mobile Computing Center.
© Cambridge University Press 2013 Thomson_Fig
By Shivaraman Janakiraman, Magesh Khanna Vadivelu.
XFEL The European X-Ray Laser Project X-Ray Free-Electron Laser Wojciech Jalmuzna, Technical University of Lodz, Department of Microelectronics and Computer.
Debugging M-Files Steve Gu Feb 08, Outline What’s Debugging? Types of Errors Finding Errors Debugging Example Using Debugging Features.
Antenna Arrays and Automotive Applications
Spectral subtraction algorithm and optimize Wanfeng Zou 7/3/2014.
1 ”MCUDA: An efficient implementation of CUDA kernels for multi-core CPUs” John A. Stratton, Sam S. Stone and Wen-mei W. Hwu Presentation for class TDT24,
Writing algorithms Introduction to Python.
Parallel Matlab programming using Distributed Arrays
Office Room: H116 Lab. : H830-1 Telephone: 4100
© Cambridge University Press 2011
Digital Decode & Correction Logic
Unit 1. Sorting and Divide and Conquer
COMPUTER NETWORKS and INTERNETS
دانشگاه شهیدرجایی تهران
Multicore Programming in pMatlab using Distributed Arrays
Chapter 1: Introduction
Thomson_eeWWtgc © Cambridge University Press 2013.
تعهدات مشتری در کنوانسیون بیع بین المللی
QPSK System Design and Simulation: Laboratory Manual
Thomson_atlascmsEventsAlt
Error control coding for wireless communication technologies
INTERMEDIATE PROGRAMMING LESSON
Introduction To Simulink
Thomson_CandP © Cambridge University Press 2013.
Do it now activity Log onto the computer.
Stored program in a washing machine
Thomson_AFBCartoon © Cambridge University Press 2013.
Presentation transcript:

Chapter 3 Interacting with Distributed Arrays Chung-Wei Chen, Department of Mathematics, National Taiwan University 2011/10/28

Outline  Introduction to Beamformer  Algorithm of Beamformer  Code of Beamformer  How to Debug  Performance  Introduction to Parrallel Pipelines

Introduction to BeamformerInteracting with Distributed Arrays3 Introduction to Beamformer

 N b point sources  Each source can emit waves of N f different frequencies  Wave emitting pattern are recorded at time t 1, …, t Nt Introduction to BeamformerInteracting with Distributed Arrays4 t1t1 f 1, …, f Nf t2t2 t Nt f 1, …, f Nf Source 1 Source 2 Source Nb f 1, …, f Nf NtNt NbNb NfNf

Introduction to Beamformer  There is a linear array of N s sensors to detect the wave emitting pattern Introduction to BeamformerInteracting with Distributed Arrays5 Source 1 Source 2 Source Nb Sensor 1 Sensor Ns Noise Steering Vector

Algorithm of BeamformerInteracting with Distributed Arrays6 Algorithm of Beamformer

 Serial: Algorithm of BeamformerInteracting with Distributed Arrays7

Algorithm of Beamformer  Parallel: Algorithm of BeamformerInteracting with Distributed Arrays8

Algorithm of Beamformer Interacting with Distributed Arrays9

Algorithm of Beamformer Interacting with Distributed Arrays10

Code of BeamformerInteracting with Distributed Arrays11 Code of Beamformer

Code of Beamformer (1/3) Code of BeamformerInteracting with Distributed Arrays12

Code of Beamformer (2/3) Code of BeamformerInteracting with Distributed Arrays13

Code of Beamformer (3/3) Code of BeamformerInteracting with Distributed Arrays14

How to DebugInteracting with Distributed Arrays15 How to Debug

 Step 1: run the program in serial on the local machine with the distributed arrays turned off  Step 2: run the program in serial on the local machine with the distributed arrays turned on  Step 3: run the program in parallel on the local machine  Step 4: run the program in parallel on the remote machine  Step 5: run the program in parallel on the remote machine but with a problem size of interest How to DebugInteracting with Distributed Arrays16 How to Debug

Interacting with Distributed Arrays17  Step 1: run the program in serial on the local machine with the distributed arrays turned off  Set PARALLEL=0  Add the following line to the end of the m-file: whos X0 X1 X2 X3 X0loc X1loc X2loc x3 myI_f myV  Type pBeamformer at the MATLAB prompt  This ensure the basic serial code is correct

How to DebugInteracting with Distributed Arrays18 How to Debug

Debug  Step 2: run the program in serial on the local machine with the distributed arrays turned on  Set PARALLEL=1  Type eval(pRUN(‘pBeamformer’,1,{})) at the MATLAB prompt  This ensure the parallel code is correct How to DebugInteracting with Distributed Arrays19

How to Debug Interacting with Distributed Arrays20

How to Debug  Step 3: run the program in parallel on the local machine  Type eval(pRUN(‘pBeamformer’,4,{})) at the MATLAB prompt  Type !type MatMPI\*.out or !more MatMPI/*.out to show the output from the other MATLABs  This will detect errors introduced by communications How to DebugInteracting with Distributed Arrays21

How to DebugInteracting with Distributed Arrays22 How to Debug

 Step 4: run the program in parallel on the remote machine  Type eval(pRUN(‘pBeamformer’,4,{‘machine1’ ‘machine2’})) at the MATLAB prompt  This will detect errors introduced by remote communications  Step 5: run the program in parallel on the remote machine but with a problem size of interest How to DebugInteracting with Distributed Arrays23 How to Debug

PerformanceInteracting with Distributed Arrays24 Performance

Interacting with Distributed Arrays25  Performance in the book  Performance of the machine Cambridge in City Cluster

Performance  The loops of Stage 1 and 2 can be combined into one loop PerformanceInteracting with Distributed Arrays26

Introduction to Parallel PipelinesInteracting with Distributed Arrays27 Introduction to Parallel Pipelines

Interacting with Distributed Arrays28

Introduction to Parallel Pipelines Interacting with Distributed Arrays29 Stage iStage i+1  Original method

 Parallel Piplines Introduction to Parallel Pipelines Interacting with Distributed Arrays30 Stage iStage i+1

Reference Interacting with Distributed Arrays31  “Parallel MATLAB for Multicore and Multinode Systems” by Jeremy Kepner, SIAM Press, 2009 Thanks for your attention!