SlideShare una empresa de Scribd logo
1 de 40
Computer Vision Techniques forInteractive ArtUsing Processing and Max/Jitter Interactive Art Doctoral Program http://www.artes.ucp.pt/si/doutoramento/index.html 28-05-2011 Jorge Cardoso 1
Topics Techniques Framedifferencing(for motiondetection) Color detection(whereintheimage, does a given color appear – can beused for trackingobjects) Brightnessdetection(whatisthepositionofthebrightestpixels) Background subtraction(for objectsegmentation)  Blobextraction(applied to theprevioustechniques to extractshapeparametersandvectorizingsilhuettes) Movementestimation (whatdirection are theobjectsmoving) Face detection(isthere a face intheimage? where?) 28-05-2011 Jorge Cardoso 2
How General overviewofhowthose CV techniqueswork Examplesofwhat can beaccomplishedwiththetechniques Vídeos Live demos ,[object Object],Some – very simple(istic) – examples of how they can be used for interactive work 28-05-2011 Jorge Cardoso 3
Computer Vision for Interaction Use a computer and camera to extract information about what people are doing and use that as an implicit or explicit form of interaction “Computer vision is the science and technology of machines that see. As a scientific discipline, computer vision is concerned with the theory for building artificial systems that obtain information from images” – Computer vision. (2009, April 24). In Wikipedia, The Free Encyclopedia. Retrieved 11:53, May 9, 2009, from http://en.wikipedia.org/w/index.php?title=Computer_vision&oldid=285848177  28-05-2011 Jorge Cardoso 4
28-05-2011 Jorge Cardoso 5 Image Computer vision are processes applied to sequences of images An image is just a sequence of number (usually arranged in a matrix form) Eachnumberrepresents a colour 50 44 23 31 38 52 75 52 29 09 15 08 38 98 53 52 08 07 12 15 24 30 51 52 10 31 14 38 32 36 53 67 14 33 38 45 53 70 69 40 36 44 58 63 47 53 35 26 68 76 74 76 55 47 38 35 69 68 63 74 50 42 35 32
Image Each pixel (i.e., number in the matrix) isusuallystoredin RGB or ARGB formatso It can be decomposed: 28-05-2011 Jorge Cardoso 6 or
Frame Differencing If we subtract two consecutive video frames, threshold and binarize it, we get a rough view of the movement in the video Procedure: Go through the current frame image, pixel by pixel Calculate the distance between the color of the current frame’s pixel and the previous frame’s pixel If distance is smaller than a given threshold, assume no movement (black), otherwise assume movement (white) 28-05-2011 Jorge Cardoso 7
Frame Differencing Color difference Q: How do wecalculatethe “distance”betweentwocolors? A: Simpleversion: euclideandistance. Take a color as a pointin 3D space (RGB -> XYZ) Calculatethedistancebetweenthetwopoints Subtracteachcomponent (dR = R1-R2, dG = G1-G2, dB = B1-B2) Dist = Sqrt(dR*dR + dG*dG + dB*dB) A1: Slightly (perceptively) betterversion: weighteachcomponentdifferently: Dist = Sqrt(2*dR*dR + 4*dG*dG + 3*dB*dB) 28-05-2011 Jorge Cardoso 8
Frame Differencing Q: What’sitgood for? A: KALOETHOGRAPHIA (2010)  Pedro Cascalheira  http://artes.ucp.pt/blogs/index.php/vai/2011/02/14/alunos-2009-2010 aB (2011)  Jorge Coutinho https://picasaweb.google.com/lh/photo/x9bGyxFsTLVFbkk9kD3xLA?feat=directlink WebCamPiano  MemoAkten [video] 28-05-2011 Jorge Cardoso 9
Frame Differencing - Code ProcessingCode FrameDifferencing FrameDifferencingWithMotionDetection FrameDifferencingForAirPiano JitterCode FrameDifferencing.maxpat FrameDifferencingWithMotionDetection.maxpat 28-05-2011 Jorge Cardoso 10
Color detection Isolate color regions in an image Procedure: Go through the image, pixel by pixel Calculate the distance between the color of the current pixel and the reference color If distance is smaller than a given threshold, keep the pixel 28-05-2011 Jorge Cardoso 11
Color Detection Color Difference For a betterapproachthan RGB distance,use HSB Give more weight to theHue Dist = Sqrt(3*dH*dH + dS*dS + 2*dB*dB) 28-05-2011 Jorge Cardoso 12
Color Detection Q: What’sitgood for? A:  Catchoftheday [video] PlayDohAsInterfaceKeyboard[video]   28-05-2011 Jorge Cardoso 13
Color Detection - Code ProcessingCode ColorDifference ColorDifferenceSequencer JitterCode ColorDifferenceWithFindbounds.maxpat ColorDifference.maxpat 28-05-2011 Jorge Cardoso 14
Brightenessdetection 15 Slightvariationon color detectionwhenwe’reonlyinterestedintrackingbrightpixels For example, to track a light Procedure: Same as color detectionbutextractthebrightnessofeach pixel andkeeponlythehighest Jorge Cardoso 28-05-2011
28-05-2011 Jorge Cardoso 16 Brighteness detection ,[object Object]
A:
In RGB:
(perceptive) Brightness = (0.2126*R) + (0.7152*G) + (0.0722*B)
(physical/energy) Brightness = (R+G+B)/3
…
In HSB:
Brightness = B  
Just use thebrightness() functioninwhateverlanguage…,[object Object]
18 Brightenessdetection ,[object Object]
A:
DrawingWith Light [video]
BurningtheSound [video]Jorge Cardoso 28-05-2011
Brightenessdetection - Code ,[object Object],BrightnessDetection ,[object Object],BrightnessDetection.maxpat 28-05-2011 Jorge Cardoso 19
Background subtraction 20 ,[object Object],          This                          -                     This                         =                 This Jorge Cardoso 28-05-2011
Background subtraction Q: How do we “subtract” two images? A: Pixel by pixel Q: How do we “subtract” two pixels? A: Channel by channel (color component by color component, usually R, G and B) 28-05-2011 Jorge Cardoso 21
Background subtraction Pixel subtraction alone doesn’t work very well due to noise or shadows in the image The resulting subtraction must be thresholded to eliminate noise 28-05-2011 Jorge Cardoso 22
Background subtraction After subtracting and thresholding, we can binarize the image to get a mask 28-05-2011 Jorge Cardoso 23
Background subtraction Q: What’sitgood for? A: Isolatingobjectsin a scenewhenyoudon’thavemuchcontroloverthe background.  Background SubtractionProcessingDemo [video] 28-05-2011 Jorge Cardoso 24
Background subtraction - Code Processingcode: BackgroundSubtraction Jittercode BackgroundSubraction.maxpat 28-05-2011 Jorge Cardoso 25
Blob extraction All the previous techniques result in possibly many white areas distributed in the image 28-05-2011 Jorge Cardoso 26 http://en.wikipedia.org/wiki/Connected_Component_Labeling
Blob extraction Blob extraction (blob detection, connected component labeling) identifies those regions and and allows the extractions of some features  area,  perimeter,  orientation,  bounding box,  Silhouette 28-05-2011 Jorge Cardoso 27
Blob extraction Procedure: See http://en.wikipedia.org/wiki/Connected_Component_Labeling 28-05-2011 Jorge Cardoso 28
Blob extraction Q:  What’sitgood for? A: Loliness (2007)  Telmo Rocha [video] Células (2009)  Ana Lima [video] SilhouetteCollisions [video] 28-05-2011 Jorge Cardoso 29
Blob extraction - Code 28-05-2011 Jorge Cardoso 30 Processing libraries

Más contenido relacionado

Destacado

Dynamic C++ ACCU 2013
Dynamic C++ ACCU 2013Dynamic C++ ACCU 2013
Dynamic C++ ACCU 2013aleks-f
 
openFrameworks 007 - utils
openFrameworks 007 - utilsopenFrameworks 007 - utils
openFrameworks 007 - utilsroxlu
 
openFrameworks 007 - events
openFrameworks 007 - eventsopenFrameworks 007 - events
openFrameworks 007 - eventsroxlu
 
openFrameworks 007 - 3D
openFrameworks 007 - 3DopenFrameworks 007 - 3D
openFrameworks 007 - 3Droxlu
 
Shadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareShadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareMark Kilgard
 
Kalman filter - Applications in Image processing
Kalman filter - Applications in Image processingKalman filter - Applications in Image processing
Kalman filter - Applications in Image processingRavi Teja
 
Hanuman Dhoka Museum Field Visit
Hanuman Dhoka Museum Field VisitHanuman Dhoka Museum Field Visit
Hanuman Dhoka Museum Field Visitamulya123
 
CFO Office case study_Commission payments for a technology company
CFO Office case study_Commission payments for a technology companyCFO Office case study_Commission payments for a technology company
CFO Office case study_Commission payments for a technology companyAmogh Giridhar
 
Economic Perspective
Economic PerspectiveEconomic Perspective
Economic PerspectiveRob Wilson
 
Kamagra Oral Jelly (Sildenafil Citrate Jelly)
Kamagra Oral Jelly (Sildenafil Citrate Jelly)Kamagra Oral Jelly (Sildenafil Citrate Jelly)
Kamagra Oral Jelly (Sildenafil Citrate Jelly)Clearsky Pharmacy
 

Destacado (12)

Dynamic C++ ACCU 2013
Dynamic C++ ACCU 2013Dynamic C++ ACCU 2013
Dynamic C++ ACCU 2013
 
openFrameworks 007 - utils
openFrameworks 007 - utilsopenFrameworks 007 - utils
openFrameworks 007 - utils
 
openFrameworks 007 - events
openFrameworks 007 - eventsopenFrameworks 007 - events
openFrameworks 007 - events
 
openFrameworks 007 - 3D
openFrameworks 007 - 3DopenFrameworks 007 - 3D
openFrameworks 007 - 3D
 
Shadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareShadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL Hardware
 
Kalman filter - Applications in Image processing
Kalman filter - Applications in Image processingKalman filter - Applications in Image processing
Kalman filter - Applications in Image processing
 
Jumbo Mail Social Media
Jumbo Mail Social MediaJumbo Mail Social Media
Jumbo Mail Social Media
 
Mkt cultural
Mkt culturalMkt cultural
Mkt cultural
 
Hanuman Dhoka Museum Field Visit
Hanuman Dhoka Museum Field VisitHanuman Dhoka Museum Field Visit
Hanuman Dhoka Museum Field Visit
 
CFO Office case study_Commission payments for a technology company
CFO Office case study_Commission payments for a technology companyCFO Office case study_Commission payments for a technology company
CFO Office case study_Commission payments for a technology company
 
Economic Perspective
Economic PerspectiveEconomic Perspective
Economic Perspective
 
Kamagra Oral Jelly (Sildenafil Citrate Jelly)
Kamagra Oral Jelly (Sildenafil Citrate Jelly)Kamagra Oral Jelly (Sildenafil Citrate Jelly)
Kamagra Oral Jelly (Sildenafil Citrate Jelly)
 

Similar a Computer vision techniques for interactive art

Image Segmentation.ppt
Image Segmentation.pptImage Segmentation.ppt
Image Segmentation.pptakshaya870130
 
People detection in a video
People detection in a videoPeople detection in a video
People detection in a videoYonatan Katz
 
Focused Image Creation Algorithms for digital holography
Focused Image Creation Algorithms for digital holographyFocused Image Creation Algorithms for digital holography
Focused Image Creation Algorithms for digital holographyConor Mc Elhinney
 
CS 354 Understanding Color
CS 354 Understanding ColorCS 354 Understanding Color
CS 354 Understanding ColorMark Kilgard
 
A Bit More Deferred Cry Engine3
A Bit More Deferred   Cry Engine3A Bit More Deferred   Cry Engine3
A Bit More Deferred Cry Engine3guest11b095
 
Image segmentation ajal
Image segmentation ajalImage segmentation ajal
Image segmentation ajalAJAL A J
 
Wavelet Applications in Image Denoising Using MATLAB
Wavelet Applications in Image Denoising Using MATLABWavelet Applications in Image Denoising Using MATLAB
Wavelet Applications in Image Denoising Using MATLABajayhakkumar
 
Computer Vision For Computer Music
Computer Vision For Computer MusicComputer Vision For Computer Music
Computer Vision For Computer MusicJorge Cardoso
 
CS 354 Pixel Updating
CS 354 Pixel UpdatingCS 354 Pixel Updating
CS 354 Pixel UpdatingMark Kilgard
 
From Image Processing To Computer Vision
From Image Processing To Computer VisionFrom Image Processing To Computer Vision
From Image Processing To Computer VisionJoud Khattab
 
Introductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT RoorkeeIntroductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT RoorkeeVinayak Sahai
 
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATION
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATIONDEEP LEARNING TECHNIQUES POWER POINT PRESENTATION
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATIONSelvaLakshmi63
 
HDR and WCG Video Broadcasting Considerations
HDR and WCG Video Broadcasting ConsiderationsHDR and WCG Video Broadcasting Considerations
HDR and WCG Video Broadcasting ConsiderationsDr. Mohieddin Moradi
 
CyberSec_JPEGcompressionForensics.pdf
CyberSec_JPEGcompressionForensics.pdfCyberSec_JPEGcompressionForensics.pdf
CyberSec_JPEGcompressionForensics.pdfMohammadAzreeYahaya
 
Summer Games University - Day 3
Summer Games University - Day 3Summer Games University - Day 3
Summer Games University - Day 3Clemens Kern
 
Open CV - 電腦怎麼看世界
Open CV - 電腦怎麼看世界Open CV - 電腦怎麼看世界
Open CV - 電腦怎麼看世界Tech Podcast Night
 
Computer Graphics Part1
Computer Graphics Part1Computer Graphics Part1
Computer Graphics Part1qpqpqp
 

Similar a Computer vision techniques for interactive art (20)

Stereo vision
Stereo visionStereo vision
Stereo vision
 
Image Segmentation.ppt
Image Segmentation.pptImage Segmentation.ppt
Image Segmentation.ppt
 
People detection in a video
People detection in a videoPeople detection in a video
People detection in a video
 
Focused Image Creation Algorithms for digital holography
Focused Image Creation Algorithms for digital holographyFocused Image Creation Algorithms for digital holography
Focused Image Creation Algorithms for digital holography
 
CS 354 Understanding Color
CS 354 Understanding ColorCS 354 Understanding Color
CS 354 Understanding Color
 
A Bit More Deferred Cry Engine3
A Bit More Deferred   Cry Engine3A Bit More Deferred   Cry Engine3
A Bit More Deferred Cry Engine3
 
Image segmentation ajal
Image segmentation ajalImage segmentation ajal
Image segmentation ajal
 
Wavelet Applications in Image Denoising Using MATLAB
Wavelet Applications in Image Denoising Using MATLABWavelet Applications in Image Denoising Using MATLAB
Wavelet Applications in Image Denoising Using MATLAB
 
Computer Vision For Computer Music
Computer Vision For Computer MusicComputer Vision For Computer Music
Computer Vision For Computer Music
 
CS 354 Pixel Updating
CS 354 Pixel UpdatingCS 354 Pixel Updating
CS 354 Pixel Updating
 
From Image Processing To Computer Vision
From Image Processing To Computer VisionFrom Image Processing To Computer Vision
From Image Processing To Computer Vision
 
Introductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT RoorkeeIntroductory Digital Image Processing using Matlab, IIT Roorkee
Introductory Digital Image Processing using Matlab, IIT Roorkee
 
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATION
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATIONDEEP LEARNING TECHNIQUES POWER POINT PRESENTATION
DEEP LEARNING TECHNIQUES POWER POINT PRESENTATION
 
HDR and WCG Principles-Part 3
HDR and WCG Principles-Part 3HDR and WCG Principles-Part 3
HDR and WCG Principles-Part 3
 
HDR and WCG Video Broadcasting Considerations
HDR and WCG Video Broadcasting ConsiderationsHDR and WCG Video Broadcasting Considerations
HDR and WCG Video Broadcasting Considerations
 
How video codec work
How video codec work How video codec work
How video codec work
 
CyberSec_JPEGcompressionForensics.pdf
CyberSec_JPEGcompressionForensics.pdfCyberSec_JPEGcompressionForensics.pdf
CyberSec_JPEGcompressionForensics.pdf
 
Summer Games University - Day 3
Summer Games University - Day 3Summer Games University - Day 3
Summer Games University - Day 3
 
Open CV - 電腦怎麼看世界
Open CV - 電腦怎麼看世界Open CV - 電腦怎麼看世界
Open CV - 電腦怎麼看世界
 
Computer Graphics Part1
Computer Graphics Part1Computer Graphics Part1
Computer Graphics Part1
 

Más de Jorge Cardoso

Criação de Ambientes de Realidade Virtual usando A-Frame - CubeCraft Toys -...
Criação de Ambientes  de Realidade Virtual  usando A-Frame - CubeCraft Toys -...Criação de Ambientes  de Realidade Virtual  usando A-Frame - CubeCraft Toys -...
Criação de Ambientes de Realidade Virtual usando A-Frame - CubeCraft Toys -...Jorge Cardoso
 
Criação de Ambientes de Realidade Virtual usando A-Frame
Criação de Ambientes  de Realidade Virtual  usando A-FrameCriação de Ambientes  de Realidade Virtual  usando A-Frame
Criação de Ambientes de Realidade Virtual usando A-FrameJorge Cardoso
 
Journal of Science and Technology of the Arts
Journal of Science and Technology of the ArtsJournal of Science and Technology of the Arts
Journal of Science and Technology of the ArtsJorge Cardoso
 
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic Augmentation
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic AugmentationEvaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic Augmentation
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic AugmentationJorge Cardoso
 
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...Jorge Cardoso
 
Digital tools for exploring roman mosaic
Digital tools for exploring roman mosaicDigital tools for exploring roman mosaic
Digital tools for exploring roman mosaicJorge Cardoso
 
Interaction techniques for locomotion in virtual reality
Interaction techniques for locomotion in virtual realityInteraction techniques for locomotion in virtual reality
Interaction techniques for locomotion in virtual realityJorge Cardoso
 
Interacção em ambientes de realidade virtual
Interacção em ambientes de realidade virtualInteracção em ambientes de realidade virtual
Interacção em ambientes de realidade virtualJorge Cardoso
 
PhD defense presentation
PhD defense presentationPhD defense presentation
PhD defense presentationJorge Cardoso
 
Dynamic graphical user interface generation for web-based public display appl...
Dynamic graphical user interface generation for web-based public display appl...Dynamic graphical user interface generation for web-based public display appl...
Dynamic graphical user interface generation for web-based public display appl...Jorge Cardoso
 
Evaluation of a programming toolkit for interactive public display applications
Evaluation of a programming toolkit for interactive public display applicationsEvaluation of a programming toolkit for interactive public display applications
Evaluation of a programming toolkit for interactive public display applicationsJorge Cardoso
 
Interaction modalities, technologies and tools for interactive art
Interaction modalities, technologies and tools for interactive artInteraction modalities, technologies and tools for interactive art
Interaction modalities, technologies and tools for interactive artJorge Cardoso
 
PuReWidgets presentation at EICS 2012
PuReWidgets presentation at EICS 2012PuReWidgets presentation at EICS 2012
PuReWidgets presentation at EICS 2012Jorge Cardoso
 
PuReWidgets toolkit
PuReWidgets toolkit PuReWidgets toolkit
PuReWidgets toolkit Jorge Cardoso
 
Assessing Feedback for Indirect Shared Interaction
Assessing Feedback for Indirect Shared InteractionAssessing Feedback for Indirect Shared Interaction
Assessing Feedback for Indirect Shared InteractionJorge Cardoso
 
Conceitos fundamentais de_programacao
Conceitos fundamentais de_programacao Conceitos fundamentais de_programacao
Conceitos fundamentais de_programacao Jorge Cardoso
 
Introdução à Programacao em Processing
Introdução à Programacao em Processing Introdução à Programacao em Processing
Introdução à Programacao em Processing Jorge Cardoso
 
Introdução à Programação para iPhone (iOS)
Introdução à Programação para iPhone (iOS)Introdução à Programação para iPhone (iOS)
Introdução à Programação para iPhone (iOS)Jorge Cardoso
 

Más de Jorge Cardoso (20)

Criação de Ambientes de Realidade Virtual usando A-Frame - CubeCraft Toys -...
Criação de Ambientes  de Realidade Virtual  usando A-Frame - CubeCraft Toys -...Criação de Ambientes  de Realidade Virtual  usando A-Frame - CubeCraft Toys -...
Criação de Ambientes de Realidade Virtual usando A-Frame - CubeCraft Toys -...
 
Criação de Ambientes de Realidade Virtual usando A-Frame
Criação de Ambientes  de Realidade Virtual  usando A-FrameCriação de Ambientes  de Realidade Virtual  usando A-Frame
Criação de Ambientes de Realidade Virtual usando A-Frame
 
Journal of Science and Technology of the Arts
Journal of Science and Technology of the ArtsJournal of Science and Technology of the Arts
Journal of Science and Technology of the Arts
 
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic Augmentation
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic AugmentationEvaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic Augmentation
Evaluation of Multi-Platform Mobile AR Frameworks for Roman Mosaic Augmentation
 
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...
ConímbrigAR A Prototype Augmented Mobile Application for Exploration of Roman...
 
Digital tools for exploring roman mosaic
Digital tools for exploring roman mosaicDigital tools for exploring roman mosaic
Digital tools for exploring roman mosaic
 
Interaction techniques for locomotion in virtual reality
Interaction techniques for locomotion in virtual realityInteraction techniques for locomotion in virtual reality
Interaction techniques for locomotion in virtual reality
 
Interacção em ambientes de realidade virtual
Interacção em ambientes de realidade virtualInteracção em ambientes de realidade virtual
Interacção em ambientes de realidade virtual
 
PhD defense presentation
PhD defense presentationPhD defense presentation
PhD defense presentation
 
Dynamic graphical user interface generation for web-based public display appl...
Dynamic graphical user interface generation for web-based public display appl...Dynamic graphical user interface generation for web-based public display appl...
Dynamic graphical user interface generation for web-based public display appl...
 
Evaluation of a programming toolkit for interactive public display applications
Evaluation of a programming toolkit for interactive public display applicationsEvaluation of a programming toolkit for interactive public display applications
Evaluation of a programming toolkit for interactive public display applications
 
Interaction modalities, technologies and tools for interactive art
Interaction modalities, technologies and tools for interactive artInteraction modalities, technologies and tools for interactive art
Interaction modalities, technologies and tools for interactive art
 
PuReWidgets toolkit
PuReWidgets toolkitPuReWidgets toolkit
PuReWidgets toolkit
 
PuReWidgets presentation at EICS 2012
PuReWidgets presentation at EICS 2012PuReWidgets presentation at EICS 2012
PuReWidgets presentation at EICS 2012
 
PuReWidgets toolkit
PuReWidgets toolkit PuReWidgets toolkit
PuReWidgets toolkit
 
Assessing Feedback for Indirect Shared Interaction
Assessing Feedback for Indirect Shared InteractionAssessing Feedback for Indirect Shared Interaction
Assessing Feedback for Indirect Shared Interaction
 
Oop java
Oop javaOop java
Oop java
 
Conceitos fundamentais de_programacao
Conceitos fundamentais de_programacao Conceitos fundamentais de_programacao
Conceitos fundamentais de_programacao
 
Introdução à Programacao em Processing
Introdução à Programacao em Processing Introdução à Programacao em Processing
Introdução à Programacao em Processing
 
Introdução à Programação para iPhone (iOS)
Introdução à Programação para iPhone (iOS)Introdução à Programação para iPhone (iOS)
Introdução à Programação para iPhone (iOS)
 

Último

ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxAreebaZafar22
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)Jisc
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...pradhanghanshyam7136
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxDr. Ravikiran H M Gowda
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxJisc
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxannathomasp01
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxmarlenawright1
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxCeline George
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxDenish Jangid
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfDr Vijay Vishwakarma
 
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Pooja Bhuva
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024Elizabeth Walsh
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibitjbellavia9
 
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...Amil baba
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...ZurliaSoop
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsKarakKing
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...Nguyen Thanh Tu Collection
 

Último (20)

ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptx
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptx
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptx
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
 
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functions
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 

Computer vision techniques for interactive art

  • 1. Computer Vision Techniques forInteractive ArtUsing Processing and Max/Jitter Interactive Art Doctoral Program http://www.artes.ucp.pt/si/doutoramento/index.html 28-05-2011 Jorge Cardoso 1
  • 2. Topics Techniques Framedifferencing(for motiondetection) Color detection(whereintheimage, does a given color appear – can beused for trackingobjects) Brightnessdetection(whatisthepositionofthebrightestpixels) Background subtraction(for objectsegmentation) Blobextraction(applied to theprevioustechniques to extractshapeparametersandvectorizingsilhuettes) Movementestimation (whatdirection are theobjectsmoving) Face detection(isthere a face intheimage? where?) 28-05-2011 Jorge Cardoso 2
  • 3.
  • 4. Computer Vision for Interaction Use a computer and camera to extract information about what people are doing and use that as an implicit or explicit form of interaction “Computer vision is the science and technology of machines that see. As a scientific discipline, computer vision is concerned with the theory for building artificial systems that obtain information from images” – Computer vision. (2009, April 24). In Wikipedia, The Free Encyclopedia. Retrieved 11:53, May 9, 2009, from http://en.wikipedia.org/w/index.php?title=Computer_vision&oldid=285848177 28-05-2011 Jorge Cardoso 4
  • 5. 28-05-2011 Jorge Cardoso 5 Image Computer vision are processes applied to sequences of images An image is just a sequence of number (usually arranged in a matrix form) Eachnumberrepresents a colour 50 44 23 31 38 52 75 52 29 09 15 08 38 98 53 52 08 07 12 15 24 30 51 52 10 31 14 38 32 36 53 67 14 33 38 45 53 70 69 40 36 44 58 63 47 53 35 26 68 76 74 76 55 47 38 35 69 68 63 74 50 42 35 32
  • 6. Image Each pixel (i.e., number in the matrix) isusuallystoredin RGB or ARGB formatso It can be decomposed: 28-05-2011 Jorge Cardoso 6 or
  • 7. Frame Differencing If we subtract two consecutive video frames, threshold and binarize it, we get a rough view of the movement in the video Procedure: Go through the current frame image, pixel by pixel Calculate the distance between the color of the current frame’s pixel and the previous frame’s pixel If distance is smaller than a given threshold, assume no movement (black), otherwise assume movement (white) 28-05-2011 Jorge Cardoso 7
  • 8. Frame Differencing Color difference Q: How do wecalculatethe “distance”betweentwocolors? A: Simpleversion: euclideandistance. Take a color as a pointin 3D space (RGB -> XYZ) Calculatethedistancebetweenthetwopoints Subtracteachcomponent (dR = R1-R2, dG = G1-G2, dB = B1-B2) Dist = Sqrt(dR*dR + dG*dG + dB*dB) A1: Slightly (perceptively) betterversion: weighteachcomponentdifferently: Dist = Sqrt(2*dR*dR + 4*dG*dG + 3*dB*dB) 28-05-2011 Jorge Cardoso 8
  • 9. Frame Differencing Q: What’sitgood for? A: KALOETHOGRAPHIA (2010) Pedro Cascalheira http://artes.ucp.pt/blogs/index.php/vai/2011/02/14/alunos-2009-2010 aB (2011) Jorge Coutinho https://picasaweb.google.com/lh/photo/x9bGyxFsTLVFbkk9kD3xLA?feat=directlink WebCamPiano MemoAkten [video] 28-05-2011 Jorge Cardoso 9
  • 10. Frame Differencing - Code ProcessingCode FrameDifferencing FrameDifferencingWithMotionDetection FrameDifferencingForAirPiano JitterCode FrameDifferencing.maxpat FrameDifferencingWithMotionDetection.maxpat 28-05-2011 Jorge Cardoso 10
  • 11. Color detection Isolate color regions in an image Procedure: Go through the image, pixel by pixel Calculate the distance between the color of the current pixel and the reference color If distance is smaller than a given threshold, keep the pixel 28-05-2011 Jorge Cardoso 11
  • 12. Color Detection Color Difference For a betterapproachthan RGB distance,use HSB Give more weight to theHue Dist = Sqrt(3*dH*dH + dS*dS + 2*dB*dB) 28-05-2011 Jorge Cardoso 12
  • 13. Color Detection Q: What’sitgood for? A: Catchoftheday [video] PlayDohAsInterfaceKeyboard[video] 28-05-2011 Jorge Cardoso 13
  • 14. Color Detection - Code ProcessingCode ColorDifference ColorDifferenceSequencer JitterCode ColorDifferenceWithFindbounds.maxpat ColorDifference.maxpat 28-05-2011 Jorge Cardoso 14
  • 15. Brightenessdetection 15 Slightvariationon color detectionwhenwe’reonlyinterestedintrackingbrightpixels For example, to track a light Procedure: Same as color detectionbutextractthebrightnessofeach pixel andkeeponlythehighest Jorge Cardoso 28-05-2011
  • 16.
  • 17. A:
  • 19. (perceptive) Brightness = (0.2126*R) + (0.7152*G) + (0.0722*B)
  • 21.
  • 24.
  • 25.
  • 26. A:
  • 29.
  • 30.
  • 31. Background subtraction Q: How do we “subtract” two images? A: Pixel by pixel Q: How do we “subtract” two pixels? A: Channel by channel (color component by color component, usually R, G and B) 28-05-2011 Jorge Cardoso 21
  • 32. Background subtraction Pixel subtraction alone doesn’t work very well due to noise or shadows in the image The resulting subtraction must be thresholded to eliminate noise 28-05-2011 Jorge Cardoso 22
  • 33. Background subtraction After subtracting and thresholding, we can binarize the image to get a mask 28-05-2011 Jorge Cardoso 23
  • 34. Background subtraction Q: What’sitgood for? A: Isolatingobjectsin a scenewhenyoudon’thavemuchcontroloverthe background. Background SubtractionProcessingDemo [video] 28-05-2011 Jorge Cardoso 24
  • 35. Background subtraction - Code Processingcode: BackgroundSubtraction Jittercode BackgroundSubraction.maxpat 28-05-2011 Jorge Cardoso 25
  • 36. Blob extraction All the previous techniques result in possibly many white areas distributed in the image 28-05-2011 Jorge Cardoso 26 http://en.wikipedia.org/wiki/Connected_Component_Labeling
  • 37. Blob extraction Blob extraction (blob detection, connected component labeling) identifies those regions and and allows the extractions of some features area, perimeter, orientation, bounding box, Silhouette 28-05-2011 Jorge Cardoso 27
  • 38. Blob extraction Procedure: See http://en.wikipedia.org/wiki/Connected_Component_Labeling 28-05-2011 Jorge Cardoso 28
  • 39. Blob extraction Q: What’sitgood for? A: Loliness (2007) Telmo Rocha [video] Células (2009) Ana Lima [video] SilhouetteCollisions [video] 28-05-2011 Jorge Cardoso 29
  • 40. Blob extraction - Code 28-05-2011 Jorge Cardoso 30 Processing libraries
  • 41.
  • 42. Blob extraction - Code Jitter Code (com external cv.jit) BlobExtractionAfterBrightnessDetection 28-05-2011 Jorge Cardoso 32
  • 43.
  • 46. For eachblockinimageone, findtheclosest (more similar) blockinimagetwo
  • 48.
  • 49. A:
  • 52.
  • 53. Face detection Notrecognition! Needs a configuration file thatdetermines what to detect (front faces, side faces, body, etc) Returnsthepositionandsizeofdetected faces 28-05-2011 Jorge Cardoso 36
  • 54. Face Detection Q: What’sitgood for? A: Anatomias Urbanas (2008) Sara Henriques [video] Ex.001 (2010) Bernardo Santos [foto] https://picasaweb.google.com/lh/photo/_KCdCQGUeEw8lSzF8ZMPVw?feat=directlink 28-05-2011 Jorge Cardoso 37
  • 55. Face Detection - Code Processing (with OpenCV processing library) FaceDetection FaceDetectionFunnyEyes Jitter (with cv.jit) FaceDetectionWithASmiley.maxpat 28-05-2011 Jorge Cardoso 38
  • 56.
  • 57. The End 28-05-2011 Jorge Cardoso 40 http://slideshare.net/jorgecardoso (tag: ea-phd-ia-2011)