untitled

Similar documents

SC-85X2取説


<4D F736F F F696E74202D C835B B E B8CDD8AB B83685D>

III


II

これわかWord2010_第1部_ indd

パワポカバー入稿用.indd

これでわかるAccess2010

卒業論文2.dvi

untitled

i

2

平成18年版 男女共同参画白書

エクセルカバー入稿用.indd

01_.g.r..


,,,,., C Java,,.,,.,., ,,.,, i


(Visual Secret Sharing Scheme) VSSS VSSS 3 i

活用ガイド (ソフトウェア編)


困ったときのQ&A



四校_目次~巻頭言.indd

ii

画像研修

21 e-learning Development of Real-time Learner Detection System for e-learning

活用ガイド (ソフトウェア編)

i

Sobel Canny i

1

はしがき・目次・事例目次・凡例.indd

G700 Camera User Guide

28 TCG SURF Card recognition using SURF in TCG play video

橡6.プログラム.doc

活用ガイド (ソフトウェア編)

17 Proposal of an Algorithm of Image Extraction and Research on Improvement of a Man-machine Interface of Food Intake Measuring System

パソコン機能ガイド

パソコン機能ガイド

『戦時経済体制の構想と展開』

ron.dvi

VB-C50i/VB-C50iR 使用説明書


Javaと.NET

, m 1 1 m m b

P2P P2P peer peer P2P peer P2P peer P2P i

カメラユーザーガイド

AF... 4 AF

, IT.,.,..,.. i

2004年度日本経団連規制改革要望


SOM SOM(Self-Organizing Maps) SOM SOM SOM SOM SOM SOM i

カメラユーザーガイド

COOLPIX A300 PDF / Adobe Acrobat Reader Adobe ibooks ios ViewNX-i / SnapBridge / / SnapBridge A12 COOLPIX A300 M

23 Study on Generation of Sudoku Problems with Fewer Clues

Web Web ID Web 16 Web Web i

(VKIR) VKIR VKIR DCT (R) (G) (B) Ward DCT i

ii

MYWORDⅤ Pro 操作マニュアル

COOLPIX S01 Aiii vii A 0

indd

Web Basic Web SAS-2 Web SAS-2 i


長崎県地域防災計画

Virtual Window System Virtual Window System Virtual Window System Virtual Window System Virtual Window System Virtual Window System Social Networking

untitled

カメラユーザーガイド

Z340_ManualCover_JP.ai

Web Web Web Web i

7,, i

PM-A850 スキャナ操作ガイド(Windows編)

™…

L30

,,.,,., II,,,.,,.,.,,,.,,,.,, II i


i


Wide Scanner TWAIN Source ユーザーズガイド

GPGPU

VG-145 / VG-140 / VG-130 / VG-120 取扱説明書

Web Web Web Web Web, i

i

活用ガイド (ハードウェア編)

untitled

カメラユーザーガイド

1 Table 1: Identification by color of voxel Voxel Mode of expression Nothing Other 1 Orange 2 Blue 3 Yellow 4 SSL Humanoid SSL-Vision 3 3 [, 21] 8 325


ii SnapBridge vi

kut-paper-template.dvi

fiš„v5.dvi

,,.,.,,.,.,.,.,,.,..,,,, i


, (GPS: Global Positioning Systemg),.,, (LBS: Local Based Services).. GPS,.,. RFID LAN,.,.,.,,,.,..,.,.,,, i

25 Removal of the fricative sounds that occur in the electronic stethoscope

RaVioli SIMD

Input image Initialize variables Loop for period of oscillation Update height map Make shade image Change property of image Output image Change time L

untitled

Transcription:

16 Edge emphasis filter of images that uses Histogram 1050307 2005 2 18

RGB 9,, i

Abstract Edge emphasis filter of images that uses Histogram Noriaki Okamoto Theedgeemphasisfilter is usually used to recognize images of a face, printed wiring board, and general scenes. In many cases, it feature of the edge is emphasized by the filter which uses an operator. However, the filters sometimes can t accurately emphasize the edges of the images. In this paper, we have been proposed a filter which emphasizes theedgebyanoperatormadewiththeimage shistogram. Moreover,wehavebeen verified another filter which made with a histogram of a non-rgb color model image. Finally, we have been used the common filter to assess the validity of the proposed filters by experimenting with nine testers. key words Histogram, Raprashian, Edge emphasis filter ii

1 1 2 3 3 5 3.1................................... 5 3.2.............................. 6 3.3................................. 6 3.3.1........................... 7 3.3.2............................. 8 3.3.3................................ 9 3.3.4................................ 11 3.3.5........................... 11 3.3.6................................ 14 4 16 4.1................................... 16 4.2................................... 17 4.3.......................... 18 4.3.1 Roberts................................ 18 4.3.2 Prewitt................................ 19 4.3.3 Sobel................................. 20 4.3.4 4................................. 21 4.3.5 8................................. 22 4.3.6 1................................ 23 iii

4.3.7 2 ( )........................ 24 4.4 Filter8............................. 25 4.5................................... 26 4.5.1..................... 26 4.5.2............... 29 4.5.3.................... 30 4.5.4...................... 32 4.6................................ 33 4.7................................... 35 5 37 5.1...................................... 37 5.2.................................. 39 40 41 A 42 B 45 C 46 iv

1.1 ( ) ( ) ( )......... 1 3.1.................... 5 3.2......................... 5 3.3................................. 9 3.4................................ 10 3.5.......................... 15 4.1 Roberts............................. 18 4.2 ( ).......................... 18 4.3 ( ) Roberts..................... 18 4.4 ( ).............................. 18 4.5 ( ) Roberts........................ 18 4.6 Prewitt............................. 19 4.7 ( ).......................... 19 4.8 ( ) Prewitt..................... 19 4.9 ( ).............................. 19 4.10 ( ) Prewitt........................ 19 4.11 Sobel.............................. 20 4.12 ( ).......................... 20 4.13 ( ) Sobel...................... 20 4.14 ( ).............................. 20 4.15 ( ) Sobel.......................... 20 4.16 ( ).......................... 21 v

4.17 ( ) 4...................... 21 4.18 ( ).............................. 21 4.19 ( ) 4......................... 21 4.20 ( ).......................... 22 4.21 ( ) 8...................... 22 4.22 ( ).............................. 22 4.23 ( ) 8......................... 22 4.24 1............................. 23 4.25 ( ).......................... 23 4.26 ( ) 1.................... 23 4.27 ( ).............................. 23 4.28 ( ) 1........................ 23 4.29 (2 ).................... 24 4.30 ( ).......................... 24 4.31 ( ) 2.................... 24 4.32 ( ).............................. 24 4.33 ( ) 2........................ 24 4.34 ( ).......................... 25 4.35 ( ) Filter8..................... 25 4.36 ( ).............................. 25 4.37 ( ) Filter8......................... 25 4.38......................... 29 4.39 HSV Filter8..... 30 4.40 YUV Filter8 ( ) ( ) 30 4.41 3 RGB HSV YUV Filter8................................ 31 vi

4.42............................. 32 4.43 2.......................... 32 4.44 Filter8........................... 32 4.45................................. 32 4.46 2............................... 32 4.47 Filter8............................... 32 4.48............................. 33 4.49 2.......................... 33 4.50 Filter8........................... 33 4.51................................. 33 4.52 2............................... 33 4.53 Filter8............................... 33 4.54................................ 34 4.55........................ 34 4.56 Filter8(HSV H) Earth.png.......... 35 4.57 Balloon.png............................. 36 4.58 Mandrill.png............................ 36 5.1.............................. 38 A.1 Aerial.eps............................. 42 A.2 Airplane.eps............................ 42 A.3 Balloon.eps............................ 42 A.4 couple.eps............................. 42 A.5 Earth.eps............................. 43 A.6 Girl.eps.............................. 43 A.7 Lenna.eps............................. 43 vii

A.8 Mandrill.eps............................ 43 A.9 milkdrop.eps........................... 44 A.10 Parrots.eps............................ 44 A.11 Pepper.eps............................. 44 A.12 Sailboat.eps............................ 44 B.1 kanban.eps( ).............. 45 B.2 kanban g.eps( )............... 45 B.3 copen.eps.................... 45 B.4 test 01.eps................... 45 C.1 c 01.eps.............................. 46 C.2 c 01n.eps............................. 46 C.3 c 02.eps.............................. 46 C.4 c 02n.eps............................. 46 viii

3.1................................ 11 3.2............................... 11 3.3.......................... 12 3.4 imgarray.java............................. 12 3.5 imgarray.java................... 13 3.6 ex fil.java............................... 14 4.1............................ 16 4.2............................. 16 4.3............................. 17 ix

1 8 2 ( ) Prewitt Sobel Prewitt Sobel 8 3 3 2-4 1 P P(i,j) Q(i,j) P P(i,j) 3 3 OP(i-1,j-1) OP(i+1,j+1) Q(i,j) 1.1 ( ) ( ) ( ) 1

Q (i,j) = 1X ³ 1X j= 1 i= 1 (OP (i,j) P (i,j) ) (1.1) 2-4 4 Q(i,j) (i,j) 24bitRGB 2

2 3 1 1 3

4

3 3.1 SIDBA Standard Image Data-BAse 3.1 Balloon.png 12 200 500 CCD 300 600 3.1 3.2 5

3.2 3.2 HSV YUV HSV YUV YUV 3.3 3 1 3 3 1 6

3.3 3 3.3.1 8 2 2 HSV YUV 2 3 3 3 3 7

3.3 3 3 HSV YUV 3 3 8 3.3.2 100 100 512 512 256 262144 512 512 100 100 0.00038146972 0.0381 500 100 0.2 20 8

3.3 3.3 3.3.3 JPEG JPEG RAW JPEG TIFF JPEG JPEG BMP 24bit PNG PNG GIF 3.4 1. JPEG PNG 9

3.3 3.4 2. 3. 0 255 4. 5. 6. 1 7. 3-4 10

3.3 3.3.4 CPU AMD AthlonXP 3000+ RAM PC3200 512MB 2 OS Windows2000Professional( ) Sun Microsystems Java 2 SDK,SE v1.4.2 EDITOR v4.14 3.1 CPU RAM OS Intel Pentium4 3.2GHz PC3200 DDR 1GB WindowsXP Professional( ) 3.2 3.3.5 4 4 2 imgarray.java 11

3.3 RGB RGB RGB 24bit 0 255 HSV YUV RGB ex fil.java main imgarray java ex fil -Filter8(RGB) test.jpg png test ex fil.class test.jpg Filter8 test Filter8.png GUI GUI ex fil.java imgarray.java 3.3 filename String pix int[] ( ) width int height int 3.4 imgarray.java 12

3.3 imgarray void String filename imgarray void int x,y, String filename imgarray void N/A getfilename String N/A setfilename void String FileName getw int N/A setw void int neww geth int N/A seth void int newh getr/g/b int int x,y RGB / / setr/g/b void int x,y,z RGB / / getrgb int int x,y 24bit RGB setrgb void int x,y,z 24bit RGB getyuv int int x,y,yuv YUV (yuv:0=y,1=u,2=v, =Y) gethsv int int x,y,hsv HSV (hsv:0=h,1=s,2=v, =H) outputimg void String outfilename PNG outputimg void String outfilename, int Fo outputimg void String outfilename, String Fo copyarray imgarray N/A 3.5 imgarray.java 3.3.5 Filter5 C Filter7 Filter5 Filter8 Filter8 Filter8 Filter5 7 0 100 Filter8 Filter5 7 0 100 0 1 0 1 13

3.3 main void String[] args F choose cmykw imgarray imgarray inarr,int C F nega imgarray imgarray inarr F gray avg imgarray imgarray inarr (RGB ) F gray rgb imgarray imgarray inarr, int C (RGB ) F gray big imgarray imgarray inarr (RGB ) F gray mini imgarray imgarray inarr (RGB ) F mirror h imgarray imgarray inarr ( ) F mirror v imgarray imgarray inarr ( ) E p diff x imgarray imgarray inarr 1 (X ) E p diff y imgarray imgarray inarr 1 (Y ) E p diff xy imgarray imgarray inarr 1 E s diff imgarray imgarray inarr E prewitt imgarray imgarray inarr Prewitt E sobel imgarray imgarray inarr Sobel E gradient imgarray imgarray inarr E roberts imgarray imgarray inarr Roberts E 4kin imgarray imgarray inarr 4 E 8kin imgarray imgarray inarr 8 E Kirsch imgarray imgarray inarr Kirsch op process imgarray imgarray inarr, int[] op 1, int[] op 2 3X3 op process spot int imgarray inarr, int[] op 1, int[] op 2, 3X3 intx,inty,intc histgram imgarray imgarray inarr (RGB ) histgram rgb imgarray imgarray inarr, int C (RGB ) data rgb imgarray imgarray inarr, String FN RGB CSV yuv imgarray imgarray inarr, String YUV YUV filter 5 imgarray imgarray inarr, int V Filter5 filter 6 imgarray imgarray inarr Filter6 filter 7 imgarray imgarray inarr Filter7 hist paint 1 imgarray imgarray inarr HSV H imgarray imgarray inarr HSV HSV S imgarray imgarray inarr HSV HSV V imgarray imgarray inarr HSV HSV RGB imgarray imgarray inarr HSV RGB SuperHistgram imgarray imgarray inarr color model imgarray imgarray inarr, String CM color model hist imgarray imgarray inarr, String CM color model hist draw imgarray imgarray inarr, String CM Filter8 imgarray imgarray inarr, String CM Filter8 Filter9 imgarray imgarray inarr, String CM Filter9 FilterA imgarray imgarray inarr, String CM FilterA FilterB imgarray imgarray inarr, String CM FilterB FilterC imgarray imgarray inarr, String CM FilterC 3.6 ex fil.java Filter8 3.3.6 14

3.3 3.5 3.5 3 3 1 9 15

4 4.1 RGB 24bit 12 4.3 4 CG 4 20 4 8 1 2 Sobel Prewitt Roberts Filter8 4.1 4.2 CPU AMD AthlonXP 3000+ RAM PC3200 512MB 2 OS Windows2000Professional( ) Sun Microsystems Java 2 SDK,SE v1.4.2 4.1 CPU RAM OS Intel PentiumM 1.7GHz PC2700 SODIM 512MB WindowsXP Home( ) MS-Office2003 Excel2003 VBA 4.2 16

4.2 4.2 FinePix S5000 310 ( 314 ) 1/2.7 CCD HR/ xd- 16MB 512MB DCF Exif Ver.2.2 JPEG /DPOF CCD- RAW 2816 2120/2048 1536/1600 1200/1280 960(pixcel) 10 f=5.7mm 57mm(35mm :37mm 370mm ) F F2.8 F3.2 F2.8 F8 10 1/3 [ ] 90cm /[ ] 2.0m, [ ] 10cm 2.0m/[ ] 90cm 2.0m AUTO ISO160 400 ISO 200 400 800 TTL64 / / / AE/ AE/ -2.0EV +2.0EV 1/3EV 2 1/2000 AF TTL AF AF / ( / / / / / ) 4.3 17

4.3 4.3 4.3.1 Roberts Roberts (x,y) (x,y+1) 4.1 4.3.1 4.3.1 Roberts 4.1 Roberts 4.2 ( ) 4.3 ( ) Roberts 4.4 ( ) 4.5 ( ) Roberts 18

4.3 4.3.2 Prewitt Prewitt 2 4.6 3 4.3.2 4.3.2 4.6 Prewitt 4.7 ( ) 4.8 ( ) Prewitt 4.9 ( ) 4.10 ( ) Prewitt 19

4.3 4.3.3 Sobel Sobel Prewitt 2 Prewitt 4.11 Sobel 4.12 ( ) 4.13 ( ) Sobel 4.14 ( ) 4.15 ( ) Sobel 20

4.3 4.3.4 4 4 4.16 ( ) 4.17 ( ) 4 4.18 ( ) 4.19 ( ) 4 21

4.3 4.3.5 8 8 4 4 4.20 ( ) 4.21 ( ) 8 4.22 ( ) 4.23 ( ) 8 22

4.3 4.3.6 1 1 3 3 4.24 2 2 2 2 2 4.24 1 4.25 ( ) 4.26 ( ) 1 4.27 ( ) 4.28 ( ) 1 23

4.3 4.3.7 2 ( ) (2 ) 4.29 (2 ) 4.30 ( ) 4.31 ( ) 2 4.32 ( ) 4.33 ( ) 2 24

4.4 Filter8 4.4 Filter8 4.34 ( ) 4.35 ( ) Filter8 4.36 ( ) 4.37 ( ) Filter8 25

4.5 4.5 4.5.1 Java Filter8 3000 public static imgarray Filter8(imgArray inarr, String CM) { System.out.println("* EDGE:Filter8(" + CM + ") [" + inarr.getfilename() + "]..."); int[][][] temparr = new int[3][inarr.getw()][inarr.geth()]; imgarray outarr = new imgarray(inarr.getw(),inarr.geth(),"filter8(" + CM + ")"); int[] hist = new int[360]; int max = 255; int big = 0; int f = 1000; if (CM.equals("RGBR")) { max = 255; } else if (CM.equals("RGBG")) { max = 255; } else if (CM.equals("RGBB")) { max = 255; } else if (CM.equals("HSVH")) { max = 359; } else if (CM.equals("HSVS")) { max = 100; } else if (CM.equals("HSVV")) { max = 100; } else if (CM.equals("YUVY")) { max = 255; } else if (CM.equals("YUVU")) { max = 255; } else if (CM.equals("YUVV")) { max = 255; } else { max = 255; } // for (int y=0; y<inarr.geth(); y++) { for (int x=0; x<inarr.getw(); x++) { int P; int R, G, B; if (CM.equals("RGBR")) { P = inarr.getr(x,y); } else if (CM.equals("RGBG")) { P = inarr.getg(x,y); } else if (CM.equals("RGBB")) { P = inarr.getb(x,y); } else if (CM.equals("HSVH")) { P = inarr.gethsv(x,y,0); if (P >= 360) { P = (P % 360); } else if (P < 0 ) { P = P + 360; } } else if (CM.equals("HSVS")) { P = inarr.gethsv(x,y,1); } else if (CM.equals("HSVV")) { P = inarr.gethsv(x,y,2); } else if (CM.equals("YUVY")) { P = inarr.getyuv(x,y,0); } else if (CM.equals("YUVU")) { P = inarr.getyuv(x,y,1); } else if (CM.equals("YUVV")) { P = inarr.getyuv(x,y,2); } else { P = 0; } 26

4.5 hist[p]++; if (hist[p] > big) { big = hist[p]; } } } // for (int y=0; y<inarr.geth(); y++) { for (int x=0; x<inarr.getw(); x++) { int P; int R, G, B; if (CM.equals("RGBR")) { P = inarr.getr(x,y); } else if (CM.equals("RGBG")) { P = inarr.getg(x,y); } else if (CM.equals("RGBB")) { P = inarr.getb(x,y); } else if (CM.equals("HSVH")) { P = inarr.gethsv(x,y,0); if (P >= 360) { P = (P % 360); } else if (P < 0 ) { P = P + 360; } } else if (CM.equals("HSVS")) { P = inarr.gethsv(x,y,1); } else if (CM.equals("HSVV")) { P = inarr.gethsv(x,y,2); } else if (CM.equals("YUVY")) { P = inarr.getyuv(x,y,0); } else if (CM.equals("YUVU")) { P = inarr.getyuv(x,y,1); } else if (CM.equals("YUVV")) { P = inarr.getyuv(x,y,2); } else { P = 0; } R = G = B = P; if (CM.equals("HSVH")) { int H, S, V; H = (P % 360); S = 100; V = 100; R = (int)((math.cos(math.max(0,math.toradians((double)(h + 0)))) * 128.0 + 64.0)); G = (int)((math.cos(math.max(0,math.toradians((double)(h + 240)))) * 128.0 + 64.0)); B = (int)((math.cos(math.max(0,math.toradians((double)(h + 120)))) * 128.0 + 64.0)); R = Math.min(255,Math.max(0,R)); G = Math.min(255,Math.max(0,G)); B = Math.min(255,Math.max(0,B)); } temparr[0][x][y] = hist[r] * f / big; temparr[1][x][y] = hist[g] * f / big; temparr[2][x][y] = hist[b] * f / big; } } for (int y=1; y<inarr.geth()-1; y++) { for (int x=1; x<inarr.getw()-1; x++) { int R, G, B; R = Math.max( Math.min( ( (inarr.getr(x+1,y ) * temparr[0][x+1][y ] ) + (inarr.getr(x-1,y ) * temparr[0][x-1][y ] ) + (inarr.getr(x,y+1) * temparr[0][x ][y+1] ) 27

4.5 + (inarr.getr(x,y-1) * temparr[0][x ][y-1] ) - (inarr.getr(x,y ) * temparr[0][x ][y ] * 4) ) / f,255),0); G = Math.max( Math.min( ( (inarr.getg(x+1,y ) * temparr[1][x+1][y ] ) + (inarr.getg(x-1,y ) * temparr[1][x-1][y ] ) + (inarr.getg(x,y+1) * temparr[1][x ][y+1] ) + (inarr.getg(x,y-1) * temparr[1][x ][y-1] ) - (inarr.getg(x,y ) * temparr[1][x ][y ] * 4) ) / f,255),0); B = Math.max( Math.min( ( (inarr.getb(x+1,y ) * temparr[2][x+1][y ] ) + (inarr.getb(x-1,y ) * temparr[2][x-1][y ] ) + (inarr.getb(x,y+1) * temparr[2][x ][y+1] ) + (inarr.getb(x,y-1) * temparr[2][x ][y-1] ) - (inarr.getb(x,y ) * temparr[2][x ][y ] * 4) ) / f,255),0); outarr.setr(x,y,r); outarr.setg(x,y,g); outarr.setb(x,y,b); } } } System.out.println(" return outarr; done."); 28

4.5 4.38 4.5.2 3 20 29

4.5 4.39 HSV Filter8 4.40 YUV Filter8 ( ) ( ) 4.5.3 RBG 24bit RGB RGB RGB 3 3 HSV YUV HSV YUV HSV HSV YUV RGB 2 RGB Filter8 30

4.5 4.41 3 RGB HSV YUV Filter8 4.39 Filter8 HSV HSV HSV H S V Filter8 4.40 YUV Filter8 YUV Y U V 4.41 RGB HSV YUV HSV YUV U V 31

4.5 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 4.5.4 (2 ) 4.42 4.43 4.44 2 Filter8 4.45 4.46 2 4.47 Filter8 32

4.6 4.48 4.49 4.50 2 Filter8 4.51 4.52 2 4.53 Filter8 4.6 1 3 8 2 1 Sobel Prewitt Filter8 6 12 4 4 20 9 4.54 4.55 2 4.55 Balloon.png Mandrill.png Filter8 Balloon.png 4.57 Filter8 Mandrill.png 4.58 33

4.6 4.54 4.55 34

4.7 4.56 Filter8(HSV H) Earth.png 4.7 2 2 2 Filter8 Filter8 HSV H 4.56 H 35

4.7 4.57 Balloon.png 4.58 Mandrill.png 36

5 5.1 2 Baloon.png 2 Filter8 4.5.4 Balloonn.png Filter8 test 01.jpg 5.1 1 Filter8 2 Filter8 37

5.1 0 1 4 4 1 Filter8 0 1 1 0 Filter8 5.1 HSV H S V YUV U V Y 38

5.2 5.2 20 Filter8 9 1 3 3 39

CAST CAST 4 4 3 4 40

[1] :,Ohmsha, p.56-62,2002. [2] :,, p.76-82,2001. [3] http://www.sp.ee.musashi-tech.ac.jp/ 41

A A.1 Aerial.eps A.2 Airplane.eps A.3 Balloon.eps A.4 couple.eps 42

A.5 Earth.eps A.6 Girl.eps A.7 Lenna.eps A.8 Mandrill.eps 43

A.9 milkdrop.eps A.10 Parrots.eps A.11 Pepper.eps A.12 Sailboat.eps 44

B B.1 B.2 kanban.eps( ) kanban g.eps( ) B.3 copen.eps B.4 test 01.eps 45

C C.1 c 01.eps C.2 c 01n.eps C.3 c 02.eps C.4 c 02n.eps 46