CN106355202A - Image feature extraction method based on K-means clustering - Google Patents
Image feature extraction method based on K-means clustering Download PDFInfo
- Publication number
- CN106355202A CN106355202A CN201610786955.3A CN201610786955A CN106355202A CN 106355202 A CN106355202 A CN 106355202A CN 201610786955 A CN201610786955 A CN 201610786955A CN 106355202 A CN106355202 A CN 106355202A
- Authority
- CN
- China
- Prior art keywords
- image
- principal component
- cluster
- vector
- component analysis
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/23—Clustering techniques
- G06F18/232—Non-hierarchical techniques
- G06F18/2321—Non-hierarchical techniques using statistics or function optimisation, e.g. modelling of probability density functions
- G06F18/23213—Non-hierarchical techniques using statistics or function optimisation, e.g. modelling of probability density functions with fixed number of clusters, e.g. K-means clustering
Landscapes
- Engineering & Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Artificial Intelligence (AREA)
- Life Sciences & Earth Sciences (AREA)
- Bioinformatics & Computational Biology (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Evolutionary Biology (AREA)
- Evolutionary Computation (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Probability & Statistics with Applications (AREA)
- Image Analysis (AREA)
Abstract
The invention provides an image feature extraction method based on K-means clustering. The method comprises steps as follows: S1: images are acquired and preprocessed, and an image database is established; S2: clustering analysis is performed on the images with a K-means clustering algorithm, and the image database is divided into K classes; S3: classified images in the image database divided into K classes are processed with a principal component analysis algorithm, and principal component analysis images are obtained; S4: the principal component analysis images are estimated according to performance indexes, and the best image is selected. The image feature extraction performance is improved, non-linear feature information in multispectral images can be effectively extracted, the defect of a large calculated amount of image feature extraction is overcome, the principal component analysis algorithm becomes more robust in combination with a conventional principal component analysis algorithm and through introduction of a Gaussian kernel function, and the method has a better effect in image feature extraction.
Description
Technical field
The present invention relates to image identification technical field is and in particular to a kind of image characteristics extraction side based on k- mean cluster
Method.
Background technology
The application that the identification of image is sorted in all applications is the most direct, and the picture data content due to obtaining is rich
Richness, the feature technology of extraction image just becomes very crucial, traditional image characteristics extraction and mainly comprises spectral signature, texture spy
Levy and shape facility.Conventional Spectra feature extraction method has PCA, k-t conversion, canonical analyses method and base
Feature extraction algorithm in genetic algorithm.PCA be in image the most frequently used a kind of become scaling method, be one kind very
Effectively feature extraction algorithm, but this algorithm needs data to be processed very big, because comprising substantial amounts of observation in image
Data, causes computation complexity and greatly increases.
In view of drawbacks described above, creator of the present invention passes through long research and practice obtains the present invention finally.
Content of the invention
For solving above-mentioned technological deficiency, the technical solution used in the present invention is, provide a kind of based on k- mean cluster
Image characteristic extracting method, the method comprises the following steps:
Step s1: collection image simultaneously carries out pretreatment to image, and set up image data base;
Step s2: using k- means clustering algorithm, cluster analyses are carried out to image, image data base is divided into k class;
Step s3: using Principal Component Analysis Algorithm, the classification chart picture in the image data base being divided into k class is processed, obtain
To principal component analysiss image;
Step s4: estimate principal component analysiss image according to performance indications, choose the best image of effect.
Preferably, state step s1 specifically including:
Step s11: image is gathered by image capture device;
Step s12: size normalization is carried out to acquired image;
Step s13: set up image data base.
Preferably, described step s2 specifically includes:
Step s21: the wave band number of every piece image and pixel count in statistical picture data base, and it is denoted as a square
Battle array x;
Step s22: the cluster class number n being specified number according to the demand input of Principal Component Analysis Algorithm;
Step s23: randomly select n object in initial matrix x as initial cluster center;
Step s24: the center being clustered according to each, calculate the distance of each object and these center object, and according to
Small distance divides to corresponding object again, forms a class;
Step s25: update cluster centre, then using the average vector of each class as new cluster centre, redistribute
Data object;
Step s26: iterate, until meet each cluster no longer change till.
Preferably, described step s3 specifically includes:
Step s31: choose the new cluster centre obtaining as new input sample;
Step s32: the sample using gaussian kernel function and new input calculates nuclear matrix k, and the computing formula of nuclear matrix k is:
In formula, xi,xjFor sample vector, c represents the sample size of input,Represent the non-linear change to sample vector
Change, k () represents gaussian kernel function;
Step s33: nuclear matrix k is normalized with the nuclear matrix k ' obtaining after normalization:
K '=(k-ack-kac+ackac)ij
In formula, acIt is c × c matrix, (ac)ij=1/c;
Step s34: calculate the eigenvalue of nuclear matrix k ' and the characteristic vector after normalization respectively, and characteristic vector is entered
Row normalized;
Step s35: eigenvalue is arranged according to order from big to small, before selection, the eigenvalue of r non-zero corresponds to
Characteristic vector αiAs principal component;
Step s36: spectral vector all of in feature space is mapped to characteristic vector corresponding with r-th eigenvalue
vr, mapping equation is:
Step s37: gained vector is reverted to image, obtains r width main constituent image, obtain all of main constituent successively
Image.
Preferably, described step s4 specifically includes:
Step s41: calculate the variance of each number of principal components evidence respectively, and to its standardization;
Step s42: calculate the ratio of each component standard variance;
Step s43: the scale according to obtaining selects the best image of effect.
Compared with prior art, the present invention provide a kind of had based on the image characteristic extracting method of k- mean cluster as follows
Benefit:
(1) k- means clustering algorithm is applied in image characteristics extraction the present invention, improves the property of image characteristics extraction
Can, the nonlinear characteristic information in multispectral image can be efficiently extracted, also improve image characteristics extraction computationally intensive simultaneously
Shortcoming.
(2) combine traditional Principal Component Analysis Algorithm, introduce gaussian kernel function so that Principal Component Analysis Algorithm becomes more
Plus robust, there is in the feature extraction of image more preferable effect.
Brief description
For the technical scheme being illustrated more clearly that in various embodiments of the present invention, below will be to required in embodiment description
The accompanying drawing using is briefly described.
Fig. 1 is a kind of flow chart of image characteristic extracting method based on k- mean cluster of the present invention;
Fig. 2 is the flow chart of step s1;
Fig. 3 is the flow chart of step s2;
Fig. 4 is the flow chart of step s3;
Fig. 5 is the flow chart of step s4.
Specific embodiment
Below in conjunction with accompanying drawing, the above-mentioned He other technical characteristic of the present invention and advantage are described in more detail.
As shown in figure 1, a kind of flow chart of the image characteristic extracting method based on k- mean cluster for the present invention, the party
Method comprises the following steps:
Step s1: collection image simultaneously carries out pretreatment to image, and set up image data base.
As shown in Fig. 2 being the flow chart of step s1, this step s1 specifically includes:
Step s11: image is gathered by image capture device.
Step s12: size normalization is carried out to acquired image.
Step s13: set up image data base.
Step s2: using k- means clustering algorithm, cluster analyses are carried out to image, image data base is divided into k class.
As shown in figure 3, being the flow chart of step s2, this step s2 specifically includes:
Step s21: the wave band number of every piece image and pixel count in statistical picture data base, and it is denoted as a square
Battle array x.
Step s22: the cluster class number n being specified number according to the demand input of Principal Component Analysis Algorithm.
Step s23: randomly select n object in initial matrix x as initial cluster center.
Step s24: the center being clustered according to each, calculate the distance of each object and these center object, and according to
Small distance divides to corresponding object again, forms a class.
Step s25: update cluster centre, then using the average vector of each class as new cluster centre, redistribute
Data object.
Step s26: iterate, until meet each cluster no longer change till.
Step s3: using Principal Component Analysis Algorithm, the classification chart picture in the image data base being divided into k class is processed, obtain
To principal component analysiss image.
As shown in figure 4, being the flow chart of step s3, this step s3 specifically includes:
Step s31: choose the new cluster centre obtaining as new input sample.
Step s32: the sample using gaussian kernel function and new input calculates nuclear matrix k, and the computing formula of nuclear matrix k is:
In formula, xi,xjFor sample vector, c represents the sample size of input,Represent the non-linear change to sample vector
Change, k () represents gaussian kernel function.
Step s33: nuclear matrix k is normalized with the nuclear matrix k ' obtaining after normalization:
K '=(k-ack-kac+ackac)ij
In formula, acIt is c × c matrix, (ac)ij=1/c.
Step s34: calculate the eigenvalue of nuclear matrix k ' and the characteristic vector after normalization respectively, and characteristic vector is entered
Row normalized.
Step s35: eigenvalue is arranged according to order from big to small, before selection, the eigenvalue of r non-zero corresponds to
Characteristic vector αiAs principal component.
Step s36: spectral vector all of in feature space is mapped to characteristic vector corresponding with r-th eigenvalue
vr, mapping equation is:
Step s37: gained vector is reverted to image, obtains r width main constituent image, obtain all of main constituent successively
Image.
Step s4: estimate principal component analysiss image according to performance indications, choose the best image of effect.
As shown in figure 5, being the flow chart of step s4, this step s4 specifically includes:
Step s41: calculate the variance of each number of principal components evidence respectively, and to its standardization.
Step s42: calculate the ratio of each component standard variance.
Step s43: the scale according to obtaining selects the best image of effect.
What the present invention provided a kind of has a following benefit based on the image characteristic extracting method of k- mean cluster:
(1) k- means clustering algorithm is applied in image characteristics extraction the present invention, improves the property of image characteristics extraction
Can, the nonlinear characteristic information in multispectral image can be efficiently extracted, also improve image characteristics extraction computationally intensive simultaneously
Shortcoming.
(2) combine traditional Principal Component Analysis Algorithm, introduce gaussian kernel function so that Principal Component Analysis Algorithm becomes more
Plus robust, there is in the feature extraction of image more preferable effect.
The foregoing is only presently preferred embodiments of the present invention, be merely illustrative for the purpose of the present invention, and non-limiting
's.Those skilled in the art understands, it can be carried out in the spirit and scope that the claims in the present invention are limited with many changes,
Modification, in addition equivalent, but fall within protection scope of the present invention.
Claims (5)
1. a kind of image characteristic extracting method based on k- mean cluster is it is characterised in that the method comprises the following steps:
Step s1: collection image simultaneously carries out pretreatment to image, and set up image data base;
Step s2: using k- means clustering algorithm, cluster analyses are carried out to image, image data base is divided into k class;
Step s3: using Principal Component Analysis Algorithm, the classification chart picture in the image data base being divided into k class is processed, led
Component analyses image;
Step s4: estimate principal component analysiss image according to performance indications, choose the best image of effect.
2. image-recognizing method according to claim 1 is it is characterised in that described step s1 specifically includes:
Step s11: image is gathered by image capture device;
Step s12: size normalization is carried out to acquired image;
Step s13: set up image data base.
3. image-recognizing method according to claim 2 is it is characterised in that described step s2 specifically includes:
Step s21: the wave band number of every piece image and pixel count in statistical picture data base, and it is denoted as a matrix x;
Step s22: the cluster class number n being specified number according to the demand input of Principal Component Analysis Algorithm;
Step s23: randomly select n object in initial matrix x as initial cluster center;
Step s24: the center being clustered according to each, calculate the distance of each object and these center object, and according to narrow spacing
From again dividing to corresponding object, form a class;
Step s25: update cluster centre, then using the average vector of each class as new cluster centre, redistribute data
Object;
Step s26: iterate, until meet each cluster no longer change till.
4. image-recognizing method according to claim 3 is it is characterised in that described step s3 specifically includes:
Step s31: choose the new cluster centre obtaining as new input sample;
Step s32: the sample using gaussian kernel function and new input calculates nuclear matrix k, and the computing formula of nuclear matrix k is:
In formula, xi,xjFor sample vector, c represents the sample size of input,Represent the nonlinear transformation to sample vector, k
() represents gaussian kernel function;
Step s33: nuclear matrix k is normalized with the nuclear matrix k ' obtaining after normalization:
K '=(k-ack-kac+ackac)ij
In formula, acIt is c × c matrix, (ac)ij=1/c;
Step s34: calculate the eigenvalue of nuclear matrix k ' and the characteristic vector after normalization respectively, and characteristic vector is returned
One change is processed;
Step s35: eigenvalue is arranged according to order from big to small, the corresponding spy of the eigenvalue of r non-zero before selection
Levy vectorial αiAs principal component;
Step s36: spectral vector all of in feature space is mapped to characteristic vector v corresponding with r-th eigenvaluer, mapping
Formula is:
Step s37: gained vector is reverted to image, obtains r width main constituent image, obtain all of main constituent figure successively
Picture.
5. image-recognizing method according to claim 4 is it is characterised in that described step s4 specifically includes:
Step s41: calculate the variance of each number of principal components evidence respectively, and to its standardization;
Step s42: calculate the ratio of each component standard variance;
Step s43: the scale according to obtaining selects the best image of effect.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610786955.3A CN106355202A (en) | 2016-08-31 | 2016-08-31 | Image feature extraction method based on K-means clustering |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610786955.3A CN106355202A (en) | 2016-08-31 | 2016-08-31 | Image feature extraction method based on K-means clustering |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106355202A true CN106355202A (en) | 2017-01-25 |
Family
ID=57856357
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610786955.3A Pending CN106355202A (en) | 2016-08-31 | 2016-08-31 | Image feature extraction method based on K-means clustering |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106355202A (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106955112A (en) * | 2017-03-17 | 2017-07-18 | 泉州装备制造研究所 | Brain wave Emotion recognition method based on Quantum wavelet neural networks model |
CN107909099A (en) * | 2017-11-10 | 2018-04-13 | 佛山科学技术学院 | A kind of threedimensional model identification and search method based on thermonuclear |
CN109359678A (en) * | 2018-10-09 | 2019-02-19 | 四川理工学院 | A kind of high-precision classification recognizer of white wine map |
CN109858529A (en) * | 2019-01-11 | 2019-06-07 | 广东工业大学 | A kind of image clustering method of scalability |
CN110647643A (en) * | 2018-06-07 | 2020-01-03 | 佳能株式会社 | Clustering method, searching method, device and storage medium of feature vector |
CN111611954A (en) * | 2020-05-28 | 2020-09-01 | 云南电网有限责任公司电力科学研究院 | Hyperspectral image classification method and device based on improved K-means algorithm |
CN113225300A (en) * | 2020-09-10 | 2021-08-06 | 深圳信息职业技术学院 | Big data analysis method based on image |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20080067793A (en) * | 2007-01-17 | 2008-07-22 | 전준철 | Real-time face recognition based on subspace and lvq classifier |
CN103456018A (en) * | 2013-09-08 | 2013-12-18 | 西安电子科技大学 | Remote sensing image change detection method based on fusion and PCA kernel fuzzy clustering |
CN103886610A (en) * | 2014-04-05 | 2014-06-25 | 东北电力大学 | Image type defect detecting method for insulator |
CN104408405A (en) * | 2014-11-03 | 2015-03-11 | 北京畅景立达软件技术有限公司 | Face representation and similarity calculation method |
CN104793606A (en) * | 2015-04-15 | 2015-07-22 | 浙江大学 | Industrial fault diagnosis method based on improved KPCA (kernel principal component analysis) and hidden Markov model |
CN104933445A (en) * | 2015-06-26 | 2015-09-23 | 电子科技大学 | Mass image classification method based on distributed K-means |
CN104951794A (en) * | 2015-05-15 | 2015-09-30 | 江南大学 | Automatic bamboo strip recognition method and system based on color and texture |
CN105335702A (en) * | 2015-10-15 | 2016-02-17 | 浙江捷尚视觉科技股份有限公司 | Bayonet vehicle type recognition method based on statistical learning |
-
2016
- 2016-08-31 CN CN201610786955.3A patent/CN106355202A/en active Pending
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20080067793A (en) * | 2007-01-17 | 2008-07-22 | 전준철 | Real-time face recognition based on subspace and lvq classifier |
CN103456018A (en) * | 2013-09-08 | 2013-12-18 | 西安电子科技大学 | Remote sensing image change detection method based on fusion and PCA kernel fuzzy clustering |
CN103886610A (en) * | 2014-04-05 | 2014-06-25 | 东北电力大学 | Image type defect detecting method for insulator |
CN104408405A (en) * | 2014-11-03 | 2015-03-11 | 北京畅景立达软件技术有限公司 | Face representation and similarity calculation method |
CN104793606A (en) * | 2015-04-15 | 2015-07-22 | 浙江大学 | Industrial fault diagnosis method based on improved KPCA (kernel principal component analysis) and hidden Markov model |
CN104951794A (en) * | 2015-05-15 | 2015-09-30 | 江南大学 | Automatic bamboo strip recognition method and system based on color and texture |
CN104933445A (en) * | 2015-06-26 | 2015-09-23 | 电子科技大学 | Mass image classification method based on distributed K-means |
CN105335702A (en) * | 2015-10-15 | 2016-02-17 | 浙江捷尚视觉科技股份有限公司 | Bayonet vehicle type recognition method based on statistical learning |
Non-Patent Citations (1)
Title |
---|
王斌会: "《多元统计分析及R语言建模 第四版》", 31 March 2016, 暨南大学出版社 * |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106955112A (en) * | 2017-03-17 | 2017-07-18 | 泉州装备制造研究所 | Brain wave Emotion recognition method based on Quantum wavelet neural networks model |
CN107909099A (en) * | 2017-11-10 | 2018-04-13 | 佛山科学技术学院 | A kind of threedimensional model identification and search method based on thermonuclear |
CN110647643A (en) * | 2018-06-07 | 2020-01-03 | 佳能株式会社 | Clustering method, searching method, device and storage medium of feature vector |
CN110647643B (en) * | 2018-06-07 | 2024-05-28 | 佳能株式会社 | Feature vector clustering method, feature vector searching method, feature vector clustering device and storage medium |
CN109359678A (en) * | 2018-10-09 | 2019-02-19 | 四川理工学院 | A kind of high-precision classification recognizer of white wine map |
CN109858529A (en) * | 2019-01-11 | 2019-06-07 | 广东工业大学 | A kind of image clustering method of scalability |
CN109858529B (en) * | 2019-01-11 | 2022-11-01 | 广东工业大学 | Scalable image clustering method |
CN111611954A (en) * | 2020-05-28 | 2020-09-01 | 云南电网有限责任公司电力科学研究院 | Hyperspectral image classification method and device based on improved K-means algorithm |
CN111611954B (en) * | 2020-05-28 | 2023-11-24 | 云南电网有限责任公司电力科学研究院 | Hyperspectral image classification method and device based on improved K-means algorithm |
CN113225300A (en) * | 2020-09-10 | 2021-08-06 | 深圳信息职业技术学院 | Big data analysis method based on image |
CN113225300B (en) * | 2020-09-10 | 2022-12-27 | 深圳信息职业技术学院 | Big data analysis method based on image |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106355202A (en) | Image feature extraction method based on K-means clustering | |
CN110399909B (en) | Hyperspectral image classification method based on label constraint elastic network graph model | |
Zheng et al. | Segmentation of green vegetation of crop canopy images based on mean shift and fisher linear discriminant | |
US9619734B2 (en) | Classification of land based on analysis of remotely-sensed earth images | |
CN107256246B (en) | printed fabric image retrieval method based on convolutional neural network | |
Cerra et al. | A fast compression-based similarity measure with applications to content-based image retrieval | |
CN109615008B (en) | Hyperspectral image classification method and system based on stack width learning | |
CN104239856B (en) | Face identification method based on Gabor characteristic and self adaptable linear regression | |
CN111160273A (en) | Hyperspectral image space spectrum combined classification method and device | |
CN107481236A (en) | A kind of quality evaluating method of screen picture | |
CN106682675B (en) | A kind of empty spectrum union feature extracting method towards high spectrum image | |
CN104021523B (en) | A kind of method of the image super-resolution amplification based on marginal classification | |
CN102903114A (en) | Hyperspectral remotely-sensed data dimensionality reduction method based on improved hierarchical clustering | |
CN103853724A (en) | Multimedia data sorting method and device | |
Kumar et al. | Near lossless image compression using parallel fractal texture identification | |
CN110298829A (en) | A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium | |
CN108520265A (en) | Method for converting image descriptor and associated picture processing equipment | |
Ma et al. | Multiscale 2-D singular spectrum analysis and principal component analysis for spatial–spectral noise-robust feature extraction and classification of hyperspectral images | |
CN105989592B (en) | Hyperspectral image waveband selection method based on double clustering and neighborhood analysis | |
CN105869161B (en) | Hyperspectral image band selection method based on image quality evaluation | |
AU2015218184A1 (en) | Processing hyperspectral or multispectral image data | |
CN111222545A (en) | Image classification method based on linear programming incremental learning | |
CN105975940A (en) | Palm print image identification method based on sparse directional two-dimensional local discriminant projection | |
CN111127407B (en) | Fourier transform-based style migration forged image detection device and method | |
CN113011467A (en) | Angelica sinensis medicinal material producing area identification method based on image structure texture information |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170125 |
|
RJ01 | Rejection of invention patent application after publication |