1 / 52

Chapter 1 - Introduction

Chapter 1 - Introduction. 1.1. Motivation 1.2. Why is Computer Vision Difficult? 1.3. Image Representation and Image Analysis 1.4. Summary. 1.1. Motivation. An image is worth thousands of words. Two principal roles of images: 1.Communication 2. Scene understanding.

rmodlin
Download Presentation

Chapter 1 - Introduction

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 1 - Introduction 1.1. Motivation 1.2. Why is Computer Vision Difficult? 1.3. Image Representation and Image Analysis 1.4. Summary

  2. 1.1. Motivation An image is worth thousands of words Two principal roles of images: 1.Communication 2. Scene understanding Objectives of image processing: 1. Human perception 2. Machine interpretation 1

  3. Human Perception Before After 2

  4. Before After 3

  5. Before After 4

  6. Before 5

  7. After 6

  8. For you, ...not much can be done! 7

  9. Machine Interpretation • Optical Character Recognition (OCR) 1 0 A Z 8

  10. 9

  11. 10

  12. Form Analysis • Documentation • License Number Identification Input image Location Recognition GG4025 11

  13. Model-based Object Recognition 12

  14. Object Models

  15. Model Matching

  16. Image Understanding • How many people, adults, and children • are there in the picture? (ii)What are their spatial relationships? (iii) Who are they? (iv) Where are they? (v) What are they doing? 15

  17. Machine interpretation of images requires diverse methods of Mathematical Engineering Biological disciplines Psycho-physiological Intelligent Scientific 16

  18. Image Analysis Low-level processing: e.g., noise removal, deblurring, and contrast enhancement Mid-level processing: e.g., edge, region, corner, and texture detections I P ===== CV High-level processing: e.g., object, function, relationship, event, and activity recognitions

  19. 1.2. Why is Computer Vision Difficult? (1) Loss of information in 3D  2D

  20. (2) Local window vs. global view

  21. (3) Sequential vs. parallel processing

  22. Sequential processing (4) Too much data (5) Noise 21

  23. 1.3. Image Representation SceneG(x,y,z): a 3-D continuous function Image F(x,y): a 2-D continuous function Discrete imageD(r,c): a 2-D discrete function Digital imageI(r,c): an array of discrete values M Origin M × N : Image size ○ N

  24. Dynamic range (or color depth): number of bits for a single pixel (a) 1 - bit: black and white (binary image) (b) 8 - bit: gray-scale (gray scale image) (c) 24 - bit: true color (color image) 23

  25. An image file is a binary file, which can be dump. • Physically, 24

  26. Types of file formats: BMP : Microsoft Bitmap formal JPEG : Joint Photographics Experts Group PNG : Portable Network Graphics TIFF : Tagged Image File Format GIF : Graphics Interchange Format HDF : Hierarchical Data Format PCX : PC Paintbrush XWD : X Window Dump ICO : ICOns CUR : CURsor 25

  27. An image file contains (a) Header: Characteristics of image Image size Color map Compression method (b) Image data: Pixel values, Index values 26

  28. Example: BMP header 27

  29. Example: 28

  30. C/C++ Program http://www.cs.ucsd.edu/classes/sp03/cse190-b/hw1/ Read header information 29

  31. Read image data 30

  32. GIF header 31

  33. Example: 32

  34. TIFF header 33

  35. Summary Two major roles of images played: (i) Communication, (ii) scene understanding Two main objectives of IP: (i) Human perception, (ii) machine interpretation Three levels of IP: Low-, mid-, and high- levels • Difficulties of computer vision: (1) Loss of information in 3D  2D (2) Noise (3) Too much data (4) Local window vs. global view (5) Sequential vs. parallel processing 34

  36. Summary • Two main objectives of IP: Human perception, Machine interpretation • Machine interpretation

  37. Three levels of IP: Low-, mid-, and high- levels • Difficulties of computer vision: (1) Loss of information in 3D  2D (2) Noise (3) Too much data (4) Local window vs. global view (5) Sequential vs. parallel processing • Dynamic range (or color depth): # bits per pixel 36

  38. OpenCV && Matlab 37

  39. Opencv 安裝 • 通常使用Visual studio C++ 搭配openCV • 也可以使用DevC++搭配(http://yester-place.blogspot.tw/2008/06/ dev-copencv.html) 38

  40. Visual C++ 2010 Express Visual express 下載 http://www.visualstudio.com/downloads/download-visual-studio-vs 39

  41. OpenCV 安裝 http://opencv.org/downloads.html 40

  42. 安裝OpenCV 切記!!! 設定完環境變數要重新開機才會生效!!! • 這邊以OpenCV 246為例 • 將opencv解壓縮至C槽(C:\OpenCV246) • 設定環境變數(我的電腦右鍵>內容>進階系統設定>環境變數 • 在環境變數PATH加上 • C:\OpenCV246\build; • C:\OpenCV246\build\x86\vc10\bin; 41

  43. 設定Visual C++ 42

  44. 對專案點右鍵>屬性 • VC++目錄>Include目錄加上 • C:\OpenCV246\build\include • C:\OpenCV246\build\include\opencv • 程式庫目錄加上 • C:\OpenCV246\build\x86\vc10\lib 43

  45. 連結器>輸入>其他相依性> • opencv_core246d.lib • opencv_calib3d246d.lib • opencv_contrib246d.lib • opencv_features2d246d.lib • opencv_highgui246d.lib • opencv_imgproc246d.lib • opencv_ml246d.lib • opencv_objdetect246d.lib • opencv_video246d.lib • opencv_videostab246d.lib • opencv_nonfree246d.lib • opencv_flann246d.lib 44

  46. OpenCV 範例-讀取圖片(Mat) Include 函式庫 imread(檔案名稱,讀取參數)參數”1”為彩色影像 imshow(視窗名稱,變數名稱) imwrite(檔案名稱,變數名稱) 45

  47. OpenCV 範例-讀取圖片(Iplimage) cvLoadImage(檔案名稱,參數) cvNamedWindow(視窗名稱,參數) 參數1為視窗自動縮放大小cvShowImage(視窗名稱,變數名稱) cvSaveImage(檔案名稱,變數名稱) 46

  48. OpenCV函式 • 讀取圖片 • Imread() • cvLoadImage() • 輸出圖片 • Imwrite() • cvSaveImage() • 讀取影片 • VideoCapture • 改變圖片大小 • cvResize() • 其餘的可以上OpenCV官網查詢 • http://docs.opencv.org/modules/refman.html 47

  49. Matlab 軟體安裝 師大校園軟體服務(http://www.itc.ntnu.edu.tw/sw/index.html) 48

  50. Matlab 安裝 解開壓縮檔後,內有一份安裝說明文件,照著文件步驟安裝即可 記得啟動時必須要用校內IP 49

More Related