最新文章专题视频专题问答1问答10问答100问答1000问答2000关键字专题1关键字专题50关键字专题500关键字专题1500TAG最新视频文章推荐1 推荐3 推荐5 推荐7 推荐9 推荐11 推荐13 推荐15 推荐17 推荐19 推荐21 推荐23 推荐25 推荐27 推荐29 推荐31 推荐33 推荐35 推荐37视频文章20视频文章30视频文章40视频文章50视频文章60 视频文章70视频文章80视频文章90视频文章100视频文章120视频文章140 视频2关键字专题关键字专题tag2tag3文章专题文章专题2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章专题3
当前位置: 首页 - 正文

车牌图像分割matlab代码

来源:动视网 责编:小OO 时间:2025-09-27 20:55:51
文档

车牌图像分割matlab代码

图像分割matlab代码作者:佚名  发布时间:2010-1-1  阅读次数:498  字体大小:【小】【中】【大】%Thisisaprogramforextractingobjectsfromanimage.Writtenforvehiclenumberplatesegmentationandextraction%Authors:JenyRajan,ChandrashekarPS%Ucanuseattachedtestimagefortestingclc;clearall;k=input('
推荐度:
导读图像分割matlab代码作者:佚名  发布时间:2010-1-1  阅读次数:498  字体大小:【小】【中】【大】%Thisisaprogramforextractingobjectsfromanimage.Writtenforvehiclenumberplatesegmentationandextraction%Authors:JenyRajan,ChandrashekarPS%Ucanuseattachedtestimagefortestingclc;clearall;k=input('
图像分割matlab代码 

作者:佚名  发布时间:2010-1-1  阅读次数:498  字体大小: 【小】 【中】【大】 

% This is a program for extracting objects from an image. Written for vehicle number plate segmentation and extraction

% Authors : Jeny Rajan, Chandrashekar P S

% U can use attached test image for testing

clc;

clear all;

k=input('Enter the file name','s'); % input image; color image

im=imread(k);

im1=rgb2gray(im);

im1=medfilt2(im1,[3 3]); %Median filtering the image to remove noise%

BW = edge(im1,'sobel'); %finding edges 

[imx,imy]=size(BW);

msk=[0 0 0 0 0;

     0 1 1 1 0;

     0 1 1 1 0;

     0 1 1 1 0;

     0 0 0 0 0;];

B=conv2(double(BW),double(msk)); %Smoothing  image to reduce the number of connected components

L = bwlabel(B,8);% Calculating connected components

mx=max(max(L))

% There will be mx connected components.Here U can give a value between 1 and mx for L or in a loop you can extract all connected components

% If you are using the attached car image, by giving 17,18,19,22,27,28 to L you can extract the number plate completely.

[r,c] = find(L==17);  

rc = [r c];

[sx sy]=size(rc);

n1=zeros(imx,imy); 

for i=1:sx

    x1=rc(i,1);

    y1=rc(i,2);

    n1(x1,y1)=255;

end % Storing the extracted image in an array

figure,imshow(im);

figure,imshow(im1);

figure,imshow(B);

figure,imshow(n1,[]);

文档

车牌图像分割matlab代码

图像分割matlab代码作者:佚名  发布时间:2010-1-1  阅读次数:498  字体大小:【小】【中】【大】%Thisisaprogramforextractingobjectsfromanimage.Writtenforvehiclenumberplatesegmentationandextraction%Authors:JenyRajan,ChandrashekarPS%Ucanuseattachedtestimagefortestingclc;clearall;k=input('
推荐度:
  • 热门焦点

最新推荐

猜你喜欢

热门推荐

专题
Top