Patrick Cozzi University of Pennsylvania CIS Spring 2011

Slides:



Advertisements
Similar presentations
CSE 781 Anti-aliasing for Texture Mapping. Quality considerations So far we just mapped one point – results in bad aliasing (resampling problems) We really.
Advertisements

Combinational Circuit Yan Gu 2 nd Presentation for CS 6260.
Parallel Prefix Sum (Scan) GPU Graphics Gary J. Katz University of Pennsylvania CIS 665 Adapted from articles taken from GPU Gems III.
CSE 113 Week 5 February , Announcements  Module 2 due 2/15  Exam 3 is on 2/15  Module 3 due 2/22  Exam 4 is on 2/25  Module 4 due 2/29.
Real Time Image Feature Vector Generator Employing Functional Cache Memory for Edge Takuki Nakagawa, Department of Electronic Engineering The University.
CSS Margins. The Margin properties define the space around elements. It is possible to use negative values to overlap content. The top, right, bottom,
Filtering Approaches for Real-Time Anti-Aliasing /
Image Processing & Perception Sec 9-11 Web Design.
Box Method for Factoring Factoring expressions in the form of.
Introduction to CUDA (1 of 2) Patrick Cozzi University of Pennsylvania CIS Spring 2012.
Introduction to CUDA 1 of 2 Patrick Cozzi University of Pennsylvania CIS Fall 2012.
CSC1401 Viewing a picture as a 2D image - 1. Review from the last week We used a getPixels() to get all of the pixels of a picture But this has been somewhat.
CUDA Performance Considerations (1 of 2) Patrick Cozzi University of Pennsylvania CIS Spring 2012.
Image Representation. Objectives  Bitmaps: resolution, colour depth and simple bitmap file calculations.  Vector graphics: drawing list – objects and.
Learning to Code a Wiki in Confluence Links Images Tables Video.
Lecture 15: Intro to Graphics Yoni Fridman 7/25/01 7/25/01.
Lecture 03 Area Based Image Processing Lecture 03 Area Based Image Processing Mata kuliah: T Computer Vision Tahun: 2010.
AFM. The cantilever holder The cantilever dimensions Tip position.
Parallel Algorithms Patrick Cozzi University of Pennsylvania CIS Spring 2012.
Parallel Algorithms Patrick Cozzi University of Pennsylvania CIS Fall 2013.
CUDA Performance Considerations (1 of 2) Patrick Cozzi University of Pennsylvania CIS Spring 2011.
Tables lab5. Drawing a table Tables are the web designer’s best friend and worst enemy. To draw a table we will use:  tag  for raw  tags for column.
Computer Science 101 Lists and Tables. Lists Unordered lists - use a bullet Ordered lists - use a number, Roman numeral, or letter.
Introduction to CUDA (1 of n*) Patrick Cozzi University of Pennsylvania CIS Spring 2011 * Where n is 2 or 3.
COMPUTER PROGRAMMING I SUMMER 2011 Objective 8.01 Understand coordinate systems. (3%)
1 Arrays of Arrays An array can represent a collection of any type of object - including other arrays! The world is filled with examples Monthly magazine:
Section 4.4. a) Factor x 2 + 5x - 36 (x + 9)(x – 4) b) Factor 2x 2 – 20x + 18 Hint: factor out a 2 first 2(x-9)(x-1) c) Factor 2x 2 + x – 6 Why doesn’t.
CS654: Digital Image Analysis
What is Matrix Multiplication? Matrix multiplication is the process of multiplying two matrices together to get another matrix. It differs from scalar.
Introduction to CUDA 1 of 2 Patrick Cozzi University of Pennsylvania CIS Fall 2014.
GPGPU: Parallel Reduction and Scan Joseph Kider University of Pennsylvania CIS Fall 2011 Credit: Patrick Cozzi, Mark Harris Suresh Venkatensuramenan.
Compressing Bi-Level Images by Block Matching on a Tree Architecture Sergio De Agostino Computer Science Department Sapienza University of Rome ITALY.
Object Oriented Programming Lecture 3: Things OO.
Table of Contents Matrices - Definition and Notation A matrix is a rectangular array of numbers. Consider the following matrix: Matrix B has 3 rows and.
CIS 681 Distributed Ray Tracing. CIS 681 Anti-Aliasing Graphics as signal processing –Scene description: continuous signal –Sample –digital representation.
Chapter 5 Integrals 5.1 Areas and Distances
CMSC5711 Image processing and computer vision
Image and Sound Representation
A Parents’ Guide to Alternative Algorithms
Matrices Rules & Operations.
Image Convolution with CUDA
Box Method for Factoring
Box Method for Factoring
Image Processing & Perception
Distributed Ray Tracing
Tables:.
CMSC5711 Revision (1) (v.7.b) revised
CS320n –Visual Programming
Measure the width of date and D on a dime
Two Way Frequency Tables
CMSC5711 Image processing and computer vision
Sequence Pair Representation
9th Lecture - Image Filters
Branch and Bound.
Pixels.
Picture This! Reducing Fractions
GPGPU: Parallel Reduction and Scan
Distributed Ray Tracing
© 2012 Elsevier, Inc. All rights reserved.
Chapter 7 Part 2 Edited by JJ Shepherd
Picture This! Reducing Fractions
Parallel build blocks.
Patrick Cozzi University of Pennsylvania CIS Spring 2011
The Normal Curve Section 7.1 & 7.2.
Convolution Layer Optimization
Winter in Kraków photographed by Marcin Ryczek
Distributed Ray Tracing
Areas and Distances In this handout: The Area problem
Building pattern  Complete the following tables and write the rule 
Digital Radio SoC Lab 2004 Spring Bit Engineering Lab., SITI.
Presentation transcript:

Patrick Cozzi University of Pennsylvania CIS 565 - Spring 2011 Summed Area Tables Patrick Cozzi University of Pennsylvania CIS 565 - Spring 2011

Summed Area Table Summed Area Table (SAT): 2D table where each element stores the sum of all elements in an input image between the lower left corner and the entry location.

Summed Area Table Example: (1 + 1 + 0) + (1 + 2 + 1) + (0 + 1 + 2) = 9 Input image SAT 2 1 4 9 12 14 1 2 2 6 9 11 1 2 1 2 5 6 8 1 1 2 1 2 2 4 (1 + 1 + 0) + (1 + 2 + 1) + (0 + 1 + 2) = 9

Summed Area Table Benefit Used to perform different width filters at every pixel in the image in constant time per pixel Just sample four pixels in SAT: w and h are the width and height of the filter kernel Image from http://http.developer.nvidia.com/GPUGems3/gpugems3_ch39.html

Summed Area Table Uses Glossy environment reflections and refractions Approximate depth of field Objects far from the focal length are blurry, while objects at the focal length are in focus. Image from http://http.developer.nvidia.com/GPUGems3/gpugems3_ch39.html

Summed Area Table Input image SAT 2 1 1 2 1 2 1 1 1 2

Summed Area Table Input image SAT 2 1 1 2 1 2 1 1 1 2 1

Summed Area Table Input image SAT 2 1 1 2 1 2 1 1 1 2 1 2

Summed Area Table Input image SAT 2 1 1 2 1 2 1 1 1 2 1 2 2

Summed Area Table Input image SAT 2 1 1 2 1 2 1 1 1 2 1 2 2 4

Summed Area Table Input image SAT 2 1 1 2 1 2 1 2 1 1 2 1 2 2 4

Summed Area Table Input image SAT 2 1 1 2 1 2 1 2 5 1 1 2 1 2 2 4

Summed Area Table …

Summed Area Table Input image SAT 2 1 4 9 1 2 2 6 9 11 1 2 1 2 5 6 8 1 1 2 1 2 2 4

Summed Area Table Input image SAT 2 1 4 9 12 1 2 2 6 9 11 1 2 1 2 5 6 8 1 1 2 1 2 2 4

Summed Area Table Input image SAT 2 1 4 9 12 14 1 2 2 6 9 11 1 2 1 2 5 6 8 1 1 2 1 2 2 4

Summed Area Table How would implement this on the GPU?

Summed Area Table Recall Inclusive Scan: 1 2 3 4 5 6 7 1 3 6 10 15 21 1 2 3 4 5 6 7 1 3 6 10 15 21 28

How would compute a SAT on the GPU using inclusive scan? Summed Area Table How would compute a SAT on the GPU using inclusive scan?

Summed Area Table Step 1 of 2: 2 1 2 3 3 3 1 2 1 3 3 1 2 1 1 3 4 4 1 1 Input image Partial SAT 2 1 2 3 3 3 1 2 1 3 3 1 2 1 1 3 4 4 1 1 2 1 2 2 4 One inclusive scan for each row

Summed Area Table Step 2 of 2: 2 3 3 3 4 9 12 14 1 3 3 2 6 9 11 1 3 4 Partial SAT Final SAT 2 3 3 3 4 9 12 14 1 3 3 2 6 9 11 1 3 4 4 2 5 6 8 1 2 2 4 1 2 2 4 One inclusive scan for each Column, bottom to top