CN106770013A - The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features - Google Patents
The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features Download PDFInfo
- Publication number
- CN106770013A CN106770013A CN201611236915.8A CN201611236915A CN106770013A CN 106770013 A CN106770013 A CN 106770013A CN 201611236915 A CN201611236915 A CN 201611236915A CN 106770013 A CN106770013 A CN 106770013A
- Authority
- CN
- China
- Prior art keywords
- spectrum
- matrix
- invariant moment
- moment features
- prime
- 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
- 238000001228 spectrum Methods 0.000 title claims abstract description 88
- 235000013336 milk Nutrition 0.000 title claims abstract description 51
- 239000008267 milk Substances 0.000 title claims abstract description 51
- 210000004080 milk Anatomy 0.000 title claims abstract description 51
- 238000000034 method Methods 0.000 title claims abstract description 48
- XSQUKJJJFZCRTK-UHFFFAOYSA-N Urea Chemical compound NC(N)=O XSQUKJJJFZCRTK-UHFFFAOYSA-N 0.000 title claims abstract description 20
- 239000004202 carbamide Substances 0.000 title claims abstract description 20
- 238000012549 training Methods 0.000 claims abstract description 37
- 235000019219 chocolate Nutrition 0.000 claims abstract description 19
- 238000005452 bending Methods 0.000 claims abstract description 12
- 238000012706 support-vector machine Methods 0.000 claims abstract description 11
- 238000000605 extraction Methods 0.000 claims abstract description 6
- 239000011159 matrix material Substances 0.000 claims description 56
- 238000002329 infrared spectrum Methods 0.000 claims description 9
- 238000005100 correlation spectroscopy Methods 0.000 claims description 6
- 238000006243 chemical reaction Methods 0.000 claims description 4
- 239000000203 mixture Substances 0.000 claims description 4
- 238000010606 normalization Methods 0.000 claims description 3
- 230000000694 effects Effects 0.000 abstract description 3
- 244000299461 Theobroma cacao Species 0.000 description 16
- 241000894007 species Species 0.000 description 14
- 238000001514 detection method Methods 0.000 description 6
- 230000004069 differentiation Effects 0.000 description 5
- 238000005516 engineering process Methods 0.000 description 5
- 235000013365 dairy product Nutrition 0.000 description 3
- 238000011160 research Methods 0.000 description 3
- 230000000875 corresponding effect Effects 0.000 description 2
- 206010016256 fatigue Diseases 0.000 description 2
- 238000000513 principal component analysis Methods 0.000 description 2
- 238000004451 qualitative analysis Methods 0.000 description 2
- 230000001360 synchronised effect Effects 0.000 description 2
- OYPRJOBELJOOCE-UHFFFAOYSA-N Calcium Chemical compound [Ca] OYPRJOBELJOOCE-UHFFFAOYSA-N 0.000 description 1
- GUBGYTABKSRVRQ-QKKXKWKRSA-N Lactose Natural products OC[C@H]1O[C@@H](O[C@H]2[C@H](O)[C@@H](O)C(O)O[C@@H]2CO)[C@H](O)[C@@H](O)[C@H]1O GUBGYTABKSRVRQ-QKKXKWKRSA-N 0.000 description 1
- 229920000877 Melamine resin Polymers 0.000 description 1
- 108010073771 Soybean Proteins Proteins 0.000 description 1
- 239000005862 Whey Substances 0.000 description 1
- 102000007544 Whey Proteins Human genes 0.000 description 1
- 108010046377 Whey Proteins Proteins 0.000 description 1
- 238000004458 analytical method Methods 0.000 description 1
- 238000013473 artificial intelligence Methods 0.000 description 1
- 229910052791 calcium Inorganic materials 0.000 description 1
- 239000011575 calcium Substances 0.000 description 1
- 238000001311 chemical methods and process Methods 0.000 description 1
- 239000003795 chemical substances by application Substances 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 239000002019 doping agent Substances 0.000 description 1
- 210000002468 fat body Anatomy 0.000 description 1
- 238000011835 investigation Methods 0.000 description 1
- 239000008101 lactose Substances 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- JDSHMPZPIAZGSV-UHFFFAOYSA-N melamine Chemical compound NC1=NC(N)=NC(N)=N1 JDSHMPZPIAZGSV-UHFFFAOYSA-N 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000009659 non-destructive testing Methods 0.000 description 1
- 238000003909 pattern recognition Methods 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 235000018102 proteins Nutrition 0.000 description 1
- 108090000623 proteins and genes Proteins 0.000 description 1
- 102000004169 proteins and genes Human genes 0.000 description 1
- 238000012372 quality testing Methods 0.000 description 1
- 239000002994 raw material Substances 0.000 description 1
- 150000003839 salts Chemical class 0.000 description 1
- 235000019710 soybean protein Nutrition 0.000 description 1
- 239000000126 substance Substances 0.000 description 1
- XLYOFNOQVPJJNP-UHFFFAOYSA-N water Substances O XLYOFNOQVPJJNP-UHFFFAOYSA-N 0.000 description 1
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01N—INVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
- G01N21/00—Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
- G01N21/17—Systems in which incident light is modified in accordance with the properties of the material investigated
- G01N21/25—Colour; Spectral properties, i.e. comparison of effect of material on the light at two or more different wavelengths or wavelength bands
- G01N21/31—Investigating relative effect of material at wavelengths characteristic of specific elements or molecules, e.g. atomic absorption spectrometry
- G01N21/35—Investigating relative effect of material at wavelengths characteristic of specific elements or molecules, e.g. atomic absorption spectrometry using infrared light
- G01N21/359—Investigating relative effect of material at wavelengths characteristic of specific elements or molecules, e.g. atomic absorption spectrometry using infrared light using near infrared light
Landscapes
- Physics & Mathematics (AREA)
- Spectroscopy & Molecular Physics (AREA)
- Health & Medical Sciences (AREA)
- Life Sciences & Earth Sciences (AREA)
- Chemical & Material Sciences (AREA)
- Analytical Chemistry (AREA)
- Biochemistry (AREA)
- General Health & Medical Sciences (AREA)
- General Physics & Mathematics (AREA)
- Immunology (AREA)
- Pathology (AREA)
- Investigating Or Analysing Materials By Optical Means (AREA)
- Image Analysis (AREA)
Abstract
The invention discloses a kind of method that doping urea milk is differentiated based on two-dimensional correlation spectra invariant moment features, comprise the following steps:1) prepare plain chocolate and doping milk as training sample, obtain the two-dimentional near-infrared correlation spectrum figure of training sample;2) theoretical according to not bending moment, extraction step 1) two-dimentional near-infrared correlation spectrum figure invariant moment features;3) using PCA to step 2) gained invariant moment features carry out preferably, obtaining preferred invariant moment features;4) supporting vector machine model is set up, Classification and Identification is carried out to the two-dimentional near-infrared correlation spectrum figure of the training sample using SVMs method;5) by the preferred invariant moment features input step 4 of the two-dimentional near-infrared correlation spectrum figure of unknown species milk) in supporting vector machine model after training, you can differentiate the species of the unknown species milk.The method of this law people can be realized being processed while mass data, and identification effect is high.
Description
Technical field
The invention belongs to milk detection technique field, relate in particular to a kind of constant based on two-dimentional near-infrared correlation spectrum
The method that moment characteristics differentiate doping urea milk.
Background technology
The various nutriments such as the protein containing needed by human body, fat, lactose, inorganic salts and calcium in milk, with people
Growth in the living standard, the demand to dairy products is also increasing.Illegal retailer under the ordering about of interests to milk in mix
The materials such as miscellaneous soybean protein, water, whey, melamine, it is right so as to cause milk safety problem to occur frequently to reduce production cost
The healthy of consumer makes a big impact.
Traditional dairy produce quality testing is mainly using some physico-chemical processes, although these method results contrasts are accurate
Really, but its process is typically complex, there are certain requirement, and time and effort consuming to experimenter, specific examination is also needed to sometimes
Agent, has destructiveness to sample, is not suitable for the timely control of quality in raw material milk purchase.Infrared Spectrum Technology its process
Simply, it is less demanding to experimenter, low cost, and without achieving that the Non-Destructive Testing to sample to sample treatment, be adapted to
Detection to dopant in dairy products.The application mainly scientific research personnel of current two-dimensional correlation spectra technology is directed to research object
With the specific outer synchronous spectrum and asynchronous spectrum disturbed, build contour form, qualitative analysis is carried out with reference to corresponding spectrum rule of reading.With section
The continuous progress of technology, two-dimensional correlation spectra technology is just towards recognizing with chemometric model, artificial intelligence is combined, real
The road of existing automatic identification.
Chinese invention patent publication number CN104316491A discloses a kind of based on synchronization-asynchronous two-dimentional near-infrared Correlated Spectroscopy
The method that urea milk is mixed in detection, the method directly will synchronous-asynchronous two-dimentional near-infrared correlation spectrum matrix and multidimensional stoichiometry
Learn the qualitative discrimination that set realizes mixing urea milk.Although its analysis result is preferably, synchronization-asynchronous two-dimentional near-infrared Correlated Spectroscopy
Matrix is three-dimensional matrice, and comprising substantial amounts of data, it is necessary to multidimensional Chemical Measurement is modeled, model is complicated, calculates the time
Long, efficiency is low.The method of discrimination for mixing urea milk proposed by the invention is built upon being carried out on the basis of extraction invariant moment features
, it is not only effectively extracted the characteristic information of two-dimentional near-infrared Correlated Spectroscopy, and have compressed data, improves modeling efficiency.
The content of the invention
In view of the shortcomings of the prior art, it is constant based on two-dimentional near-infrared correlation spectrum it is an object of the invention to provide one kind
The method that moment characteristics differentiate doping urea milk, the method sets up classification using the characteristic signal of algorithm of support vector machine and sample
Device, by extracting two-dimentional near-infrared correlation spectrum invariant moment features and the algorithm of support vector machine scale-model investigation to sample classification,
Whether detection milk adulterates.
The purpose of the present invention is achieved by following technical proposals.
A kind of method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features, including following step
Suddenly:
1) prepare plain chocolate and doping milk as training sample, the one-dimensional near red of the training sample is obtained by scanning
External spectrum, and Correlated Spectroscopy calculating is carried out by Noda theories, obtain the synchronous-asynchronous two-dimentional near-infrared of each training sample
Light spectrum matrix (detailed calculating process is shown in that Yang Ren outstanding persons is based on Two-dimensional spectrum doping milk detection method research [D] University Of Tianjin,
2013.), and by resulting synchronous-asynchronous two-dimentional near infrared light spectrum matrix two-dimentional near-infrared correlation spectrum figure is changed into;
In the step 1) in, the synchronous-asynchronous two-dimentional near infrared light spectrum matrix changes into two-dimentional near-infrared correlation light
The method of spectrogram is:By the data normalization of the synchronous-asynchronous two-dimentional near infrared light spectrum matrix between 0-255, pass through
The image orders of matlab softwares obtain the two-dimentional near-infrared correlation spectrum figure.
In the above-mentioned technical solutions, using deviation standardization (min-max standardization) to the synchronous-asynchronous near-infrared
The data of two-dimension spectrum matrix are normalized, and the standardized conversion formula of deviation is:
New data=(minimums of former data-original data) * 255/ (minimums of the maximum of former data-original data)
(1)
Wherein, former data are the data of not normalized synchronous-asynchronous two-dimentional near infrared light spectrum matrix, and new data is to return
The data of the synchronous-asynchronous two-dimentional near infrared light spectrum matrix after one change.
2) theoretical according to not bending moment, extraction step 1) the two-dimentional near-infrared correlation spectrum figure of gained invariant moment features;
In the step 2) in, the method for extracting invariant moment features is:
1. two-dimensional matrix f (x, y) of the described two-dimentional near-infrared correlation spectrum figure of m × n is calculated according to formula (2) and (3)
P+q rank central moments upq:
Wherein, p and q are integer, and p and q=0,1,2 and 3, f (x, y) are the synchronous-asynchronous two-dimentional near-infrared for being obtained
Light spectrum matrix is by the two-dimensional matrix after method for normalizing conversion, M00It is the Two-Dimensional Moment of the two-dimentional near-infrared correlation spectrum figure
The zeroth order square of battle array f (x, y), M10And M01It is the first moment of two-dimensional matrix f (x, y) of the two-dimentional near-infrared correlation spectrum figure;
2. the M of two-dimensional matrix f (x, y) of the two-dimentional near-infrared correlation spectrum figure is calculated by formula (4)00、M10With
M01:
Wherein, m × n is the resolution ratio of the two-dimentional near-infrared correlation spectrum figure.
3. as formula (5) to step it is 1. middle obtained by p+q rank central moments upqIt is normalized, obtains ηpq,
ηpq=upq/u00 γ (5)
Wherein,
4. by step 3. gained ηpqFormula (6) is substituted into successively, obtains invariant moment features φ1、φ2、φ3、φ4、φ5、φ6
And φ7。
3) using PCA to step 2) gained invariant moment features carry out preferably, obtaining preferred invariant moment features;
In the step 3) in, to step 2) gained invariant moment features carry out preferred method and are:
I is trained the invariant moment features composition characteristic data matrix X '=(x of sample by multiple according to formula (7)ij')s×l:
Wherein, xij' it is i-th j-th invariant moment features parameter of training sample, l is invariant moment features number, and s is instruction
Practice the number of sample;Characteristic matrix X ' described in standardization, obtains X=(xij)s×l, wherein,
Wherein,
II calculates the coefficient correlation of X according to formula (11), obtains correlation matrix R=(rij)s×l:
III calculates the characteristic value (λ of the correlation matrix R1,λ2,…,λl);
IV calculates contribution rate:Step III gained characteristic values are substituted into formula (12) successively, l contribution rate is obtained;
V determines principal component:L step IV gained contribution rate is arranged and added up from big to small, contribution rate is chosen and is tired out
It is value added be more than or equal to 85% preceding t principal component, determine the t principal component invariant moment features be preferred invariant moment features.
4) set up supporting vector machine model, using SVMs method to it is described training sample two-dimentional near-infrared correlation light
Spectrogram carries out Classification and Identification, is input into as step 3) obtained by preferred invariant moment features, be output as train sample species:Plain chocolate
Or doping milk, wherein, call the training function Svmtrain of supporting vector machine model to be trained the training sample;
5) calculate according to the method described above unknown species milk two-dimentional near-infrared correlation spectrum figure preferably bending moment is special, will
The preferred invariant moment features input step 4 of the two-dimentional near-infrared correlation spectrum figure of unknown species milk) in training after support to
In amount machine model, you can differentiate the species of the unknown species milk.
Compared to prior art, the method for the present invention is characterized pure using the invariant moment features of two-dimentional near-infrared correlation spectrum figure
The information that milk is included with doping milk, image processing techniques is combined with milk doping differentiation, is different from conventional
The synchronous spectrum and asynchronous spectrum of contour form are built, qualitative analysis is carried out with reference to corresponding spectrum rule of reading.The method can be realized largely
Processed while data, identification effect is high.In addition, the present invention is by two-dimentional near-infrared correlation spectrum figure invariant moment features and props up
Vector machine is held to be combined, by extract the invariant moment features of two-dimentional near-infrared correlation spectrum figure by two-dimentional near-infrared spectrum technique with
Pattern-recognition is combined, and realizes the qualitative discrimination of doping milk and plain chocolate.Spectrogram human eye is the method overcome directly to compare
To haveing the shortcomings that subjective erroneous judgement and largely spectrogram cannot compare simultaneously, identification effect and accuracy are high.
Brief description of the drawings
Fig. 1 is the flow chart of the inventive method;
Fig. 2 is the schematic diagram of SVMs.
Specific embodiment
Below in conjunction with the accompanying drawings technical scheme is further illustrated with specific embodiment.
As shown in Fig. 1~2, a kind of method that doping urea milk is differentiated based on two-dimensional correlation spectra invariant moment features, bag
Include following steps:
1) prepare plain chocolate and doping milk as training sample, the one-dimensional near red of the training sample is obtained by scanning
External spectrum, and Correlated Spectroscopy calculating is carried out by Noda theories, obtain the synchronous-asynchronous two-dimentional near-infrared of each training sample
Light spectrum matrix, two-dimentional near-infrared correlation spectrum figure is changed into by the synchronous-asynchronous two-dimentional near infrared light spectrum matrix, sets up sample
Product picture library.
Wherein, the method for obtaining synchronous-asynchronous two-dimentional near infrared light spectrum matrix is recorded in Publication No.:
(also refer to document Yang Ren outstanding persons to be ground based on Two-dimensional spectrum doping milk detection method in the patent of invention of CN104316491A
Study carefully [D] University Of Tianjin, 2013).Synchronous-asynchronous near-infrared two-dimension spectrum matrix changes into two-dimentional near-infrared correlation spectrum figure
Method is:By the data normalization of the synchronous-asynchronous two-dimentional near infrared light spectrum matrix between 0-255, normalized side
Method has many kinds, using deviation standardization (min-max standardization) to synchronous-asynchronous in specific embodiment of the invention
The data of two-dimentional near infrared light spectrum matrix are normalized, and end value is mapped between [0-255].The standardized conversion of deviation
Formula is:
New data=(minimums of former data-original data) * 255/ (minimums of the maximum of former data-original data)
(1)
Wherein, former data are the data of not normalized synchronous-asynchronous two-dimentional near infrared light spectrum matrix, and new data is to return
The data of the synchronous-asynchronous two-dimentional near infrared light spectrum matrix after one change.
Data to normalized synchronous-asynchronous two-dimentional near infrared light spectrum matrix are ordered using the image () of matlab softwares
Order can obtain two-dimentional near-infrared correlation spectrum figure.
2) theoretical according to not bending moment, extraction step 1) the two-dimentional near-infrared correlation spectrum figure of gained invariant moment features;
In the step 2) in, the method for extracting invariant moment features is:
1. two-dimensional matrix f (x, y) of the described two-dimentional near-infrared correlation spectrum figure of m × n is calculated according to formula (2) and (3)
P+q rank central moments upq:
Wherein, p and q are integer, and p and q=0,1,2 and 3, f (x, y) are synchronous-asynchronous two-dimentional near infrared light spectrum matrix
Two-dimensional matrix after being converted by foregoing method for normalizing, M00It is the two-dimensional matrix of the two-dimensional correlation spectra figure
The zeroth order square of f (x, y), M10And M01It is two-dimensional matrix f (x, y) of the two-dimentional near-infrared correlation spectrum figure
First moment;
2. the M of two-dimensional matrix f (x, y) of two-dimentional near-infrared correlation spectrum figure is calculated by formula (4)00、M10And M01:
Wherein, m × n is the resolution ratio of the two-dimentional near-infrared correlation spectrum figure.
3. as formula (5) to step it is 1. middle obtained by p+q rank central moments upqIt is normalized, obtains ηpq,
ηpq=upq/u00 γ (5)
Wherein,
4. by step 3. gained ηpqFormula (6) is substituted into successively, obtains invariant moment features φ1、φ2、φ3、φ4、φ5、φ6
And φ7。
3) using PCA to step 2) gained invariant moment features carry out preferably, obtaining preferred invariant moment features;
Wherein, to step 2) gained invariant moment features carry out preferred method and are:
I is trained the invariant moment features composition characteristic data matrix X '=(x of sample by multiple according to formula (7)ij')s×l:
Wherein, xij' it is i-th j-th invariant moment features parameter of training sample, l is invariant moment features number, and s is instruction
Practice the number of sample;Original invariant moment features data dimension is different, certain influence can be produced to result, in order to eliminate difference
The dimension impact of invariant moment features, it is necessary to characteristic matrix X ' described in standardization, obtains X=(xij)s×l, wherein,
Wherein,
II calculates the coefficient correlation of X according to formula (11), obtains correlation matrix R=(rij)s×l:
III calculates the characteristic value (λ of the correlation matrix R1,λ2,…,λl);
IV calculates contribution rate:Contribution rate refers to that the variance of certain principal component accounts for the proportion of whole variances, it is actual namely certain
Individual characteristic value accounts for the total proportion of All Eigenvalues.Step III gained characteristic values are substituted into formula (12) successively, l tribute is obtained
Offer rate;
V determines principal component:L step IV gained contribution rate is arranged and added up from big to small, contribution rate is chosen and is tired out
It is value added be more than or equal to 85% preceding t principal component, determine the t principal component invariant moment features be preferred invariant moment features;
4) SVMs (SVM) model, SVMs principle are set up as shown in Fig. 2 input is for X1, X2 ..., Xn,
Y is output as, inner product kernel function is K1 (X), K2 (X) ... ..., Kn (X).Using SVMs method to the two of the training sample
Dimension near-infrared correlation spectrum figure carry out Classification and Identification, be input into as step 3) obtained by preferred invariant moment features, be output as train sample
The species of product:Plain chocolate or doping milk, wherein, the training function Svmtrain of supporting vector machine model is called to the training
Sample is trained;
5) by the preferred invariant moment features input step 4 of the two-dimentional near-infrared correlation spectrum figure of unknown species milk) middle instruction
In supporting vector machine model after white silk, you can differentiate the species of the unknown species milk.
Below by taking plain chocolate and doping urea milk as an example, technical method of the invention is illustrated.
1) prepare 27 plain chocolates and 27 doping urea milk as training sample, 54 training samples are obtained by scanning
The synchronization of product-asynchronous two-dimentional near infrared light spectrum matrix, two-dimentional near-infrared is changed into by synchronization-asynchronous two-dimentional near infrared light spectrum matrix
Correlation spectrum figure;
2) theoretical according to not bending moment, extraction step 1) the two-dimentional near-infrared correlation spectrum figure of gained invariant moment features, the He of table 1
Table 2 is respectively 5 plain chocolates and 5 invariant moment features data of doping urea milk in 54 training samples;
The invariant moment features data of the synchronization of the plain chocolate of table 1-asynchronous two-dimentional atlas of near infrared spectra
The invariant moment features data of the synchronization-asynchronous two-dimentional atlas of near infrared spectra of the doping urea milk of table 2
3) using PCA to step 2) gained invariant moment features carry out preferably, obtain 4 preferably bending moment spy
Levy, as shown in table 3.
The principal component analysis result of table 3
As shown in Table 3, by principal component analysis, plain chocolate with doping urea synchronous-asynchronous two-dimentional atlas of near infrared spectra
Preceding 4 principal component contribution rate of accumulative total be 92.94%, reach more than 85%, can very well extract the distribution of former characteristic statistic
Characteristic, i.e. not bending moment φ1, not bending moment φ3, not bending moment φ2Not bending moment φ6It is preferred invariant moment features.
4) set up supporting vector machine model, using SVMs method to it is described training sample two-dimentional near-infrared correlation light
Spectrogram carries out Classification and Identification, is input into as step 3) obtained by 54 training sample preferred invariant moment features, be output as train sample
The species of product:Plain chocolate or doping milk, wherein, the training function Svmtrain of supporting vector machine model is called to the training
Sample is trained.External prediction is carried out to calibration set using supporting vector machine model, its result shows, in 54 training samples
There are 3 differentiation mistakes, wherein there is a plain chocolate to be mistaken for the milk of doping urea, two doping urea milk are not mistaken for
Plain chocolate.Built supporting vector machine model is 94.4444% to the differentiation accuracy rate of calibration set.
5) using 13 plain chocolates and 13 doping urea milk as unknown species milk, by 26 unknown species milk
The preferred invariant moment features input step 4 of two-dimentional near-infrared correlation spectrum figure) in training after supporting vector machine model in, you can
Differentiate the species of the unknown species milk.External prediction is carried out to calibration set using model, its result shows, 26 sample numbers
There are 4 differentiation mistakes in, wherein plain chocolate differentiates that result is all correct, and the milk of 4 doping urea is mistaken for plain chocolate.Institute
Established model is 84.6154% to the differentiation accuracy rate of calibration set.
Exemplary description is done to the present invention above, it should explanation, do not departed from the situation of core of the invention
Under, any simple deformation, modification or other skilled in the art can not spend the equivalent of creative work equal
Fall into protection scope of the present invention.
Claims (5)
1. it is a kind of based on two-dimensional correlation spectra invariant moment features differentiate doping urea milk method, it is characterised in that including with
Lower step:
1) prepare plain chocolate and doping milk as training sample, the one-dimensional near infrared light of the training sample is obtained by scanning
Spectrum, and Correlated Spectroscopy calculating is carried out by Noda theories, obtain the synchronous-asynchronous two-dimentional near infrared spectrum of each training sample
Matrix, and resulting synchronous-asynchronous two-dimentional near infrared light spectrum matrix is changed into two-dimentional near-infrared correlation spectrum figure;
2) theoretical according to not bending moment, extraction step 1) the two-dimentional near-infrared correlation spectrum figure of gained invariant moment features;
3) using PCA to step 2) gained invariant moment features carry out preferably, obtaining preferred invariant moment features;
4) set up supporting vector machine model, using SVMs method to it is described training sample two-dimentional near-infrared correlation spectrum figure
Carry out Classification and Identification, be input into as step 3) obtained by preferred invariant moment features, be output as train sample species:Plain chocolate is mixed
Miscellaneous milk, wherein, call the training function Svmtrain of supporting vector machine model to be trained the training sample;
5) by the preferred invariant moment features input step 4 of the two-dimentional near-infrared correlation spectrum figure of unknown species milk) in training after
Supporting vector machine model in, you can differentiate the species of the unknown species milk.
2. method according to claim 1, it is characterised in that in the step 1) in, the synchronous-asynchronous two dimension is near
The method that infrared spectrum matrix changes into two-dimentional near-infrared correlation spectrum figure is:By the synchronous-asynchronous two-dimentional near infrared spectrum
The data normalization of matrix obtains the two-dimentional near-infrared correlation light between 0-255 by the image orders of matlab softwares
Spectrogram.
3. method according to claim 2, it is characterised in that near to the synchronous-asynchronous two dimension using deviation standardization
The data of infrared spectrum matrix are normalized, and the standardized conversion formula of deviation is:
New data=(minimums of former data-original data) * 255/ (minimums of the maximum of former data-original data) (1) its
In, former data are the data of not normalized synchronous-asynchronous two-dimentional near infrared light spectrum matrix, and new data is same after normalizing
The data of step-asynchronous two-dimentional near infrared light spectrum matrix.
4. method according to claim 3, it is characterised in that in the step 2) in, the method for extracting invariant moment features
For:
1. the p+q of two-dimensional matrix f (x, y) of the described two-dimentional near-infrared correlation spectrum figure of m × n is calculated according to formula (2) and (3)
Rank central moment upq:
Wherein, p and q are integer, and p, q=0,1,2 and 3, f (x, y) are the synchronous-asynchronous two-dimentional near infrared light spectrum matrix
Two-dimensional matrix after being converted according to method for normalizing described in claim 3, M00It is the two of the two-dimentional near-infrared correlation spectrum figure
The zeroth order square of dimension matrix f (x, y), M10And M01It is the one of two-dimensional matrix f (x, y) of the two-dimentional near-infrared correlation spectrum figure
Rank square;
2. the M of two-dimensional matrix f (x, y) of the two-dimentional near-infrared correlation spectrum figure is calculated by formula (4)00、M10And M01:
Wherein, m × n is the resolution ratio of the two-dimentional near-infrared correlation spectrum figure.
3. as formula (5) to step it is 1. middle obtained by p+q rank central moments upqIt is normalized, obtains ηpq,
ηpq=upq/u00 γ (5)
Wherein,
4. by step 3. gained ηpqFormula (6) is substituted into successively, obtains invariant moment features φ1、φ2、φ3、φ4、φ5、φ6With
φ7。
5. method according to claim 1, it is characterised in that in the step 3) in, to step 2) bending moment is not special for gained
Levying carries out preferred method and is:
I is trained the invariant moment features composition characteristic data matrix X '=(x of sample by multiple according to formula (7)ij')s×l:
Wherein, xij' it is i-th j-th invariant moment features parameter of training sample, l is invariant moment features number, and s is training sample
The number of product;Characteristic matrix X ' described in standardization, obtains X=(xij)s×l, wherein,
Wherein,
II calculates the coefficient correlation of X according to formula (11), obtains correlation matrix R=(rij)s×l:
III calculates the characteristic value (λ of the correlation matrix R1,λ2,…,λl);
IV calculates contribution rate:Step III gained characteristic values are substituted into formula (12) successively, l contribution rate is obtained;
V determines principal component:L step IV gained contribution rate is arranged and added up from big to small, contribution rate accumulated value is chosen
Preceding t principal component more than or equal to 85%, the invariant moment features for determining the t principal component are preferred invariant moment features.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611236915.8A CN106770013A (en) | 2016-12-28 | 2016-12-28 | The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611236915.8A CN106770013A (en) | 2016-12-28 | 2016-12-28 | The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106770013A true CN106770013A (en) | 2017-05-31 |
Family
ID=58924857
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201611236915.8A Pending CN106770013A (en) | 2016-12-28 | 2016-12-28 | The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106770013A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107561031A (en) * | 2017-08-29 | 2018-01-09 | 天津农学院 | Based on two-dimentional near-infrared, in infrared Correlated Spectroscopy information fusion sesame oil in mix corn oil detection method |
WO2018227338A1 (en) * | 2017-06-12 | 2018-12-20 | 深圳前海达闼云端智能科技有限公司 | Method, apparatus and device for detecting composition of substance |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103792198A (en) * | 2014-02-24 | 2014-05-14 | 天津农学院 | Intermediate infrared-near infrared correlation spectrum discriminating method for melamine-doped milk |
CN103823158A (en) * | 2014-02-19 | 2014-05-28 | 福州大学 | Resonant earthed system fault line selection method with invariant moments |
CN104316491A (en) * | 2014-11-12 | 2015-01-28 | 天津农学院 | Method for detecting urea doped in milk based on synchronous-asynchronous two-dimensional near-infrared correlation spectrum |
CN105675562A (en) * | 2016-01-20 | 2016-06-15 | 天津农学院 | In-water polycyclic aromatic hydrocarbon detection method based on two-dimensional fluorescence correlation spectroscopy |
-
2016
- 2016-12-28 CN CN201611236915.8A patent/CN106770013A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103823158A (en) * | 2014-02-19 | 2014-05-28 | 福州大学 | Resonant earthed system fault line selection method with invariant moments |
CN103792198A (en) * | 2014-02-24 | 2014-05-14 | 天津农学院 | Intermediate infrared-near infrared correlation spectrum discriminating method for melamine-doped milk |
CN104316491A (en) * | 2014-11-12 | 2015-01-28 | 天津农学院 | Method for detecting urea doped in milk based on synchronous-asynchronous two-dimensional near-infrared correlation spectrum |
CN105675562A (en) * | 2016-01-20 | 2016-06-15 | 天津农学院 | In-water polycyclic aromatic hydrocarbon detection method based on two-dimensional fluorescence correlation spectroscopy |
Non-Patent Citations (1)
Title |
---|
周云蕾等: "基于多特征和支持向量机的风景图像分类", 《计算机系统应用》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018227338A1 (en) * | 2017-06-12 | 2018-12-20 | 深圳前海达闼云端智能科技有限公司 | Method, apparatus and device for detecting composition of substance |
US11468264B2 (en) | 2017-06-12 | 2022-10-11 | Beijing Cloudoptek Technology Co., Ltd. | Substance ingredient detection method and apparatus, and detection device |
CN107561031A (en) * | 2017-08-29 | 2018-01-09 | 天津农学院 | Based on two-dimentional near-infrared, in infrared Correlated Spectroscopy information fusion sesame oil in mix corn oil detection method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104374738B (en) | A kind of method for qualitative analysis improving identification result based on near-infrared | |
CN104008375B (en) | The integrated face identification method of feature based fusion | |
CN105021529B (en) | Fusion spectrum and the crop disease and insect of image information identify and distinguish between method | |
CN105181650B (en) | A method of quickly differentiating local tea variety using near-infrared spectrum technique | |
Shafiee et al. | Potential application of machine vision to honey characterization | |
CN103278464A (en) | Method and device for fish flesh detection | |
CN104866871B (en) | Hyperspectral image classification method based on projection structure sparse coding | |
CN106404689A (en) | Identification method of components of exocarpium | |
Liu et al. | Rapid identification of chrysanthemum teas by computer vision and deep learning | |
CN106841053B (en) | A kind of jujube kind rapid identification method | |
CN113989623A (en) | Automatic identification method for traditional Chinese medicine decoction piece image | |
CN108154133A (en) | Human face portrait based on asymmetric combination learning-photo array method | |
Ren et al. | Evaluating Congou black tea quality using a lab-made computer vision system coupled with morphological features and chemometrics | |
Jacquot et al. | Potential of multispectral Imager to characterize anisotropic French PDO cheeses: A feasibility study | |
CN106770013A (en) | The method that doping urea milk is differentiated based on two-dimentional near-infrared correlation spectrum invariant moment features | |
CN116385819A (en) | Water quality evaluation method, device and equipment based on neural network model | |
Ni et al. | Detection of carrot quality using DCGAN and deep network with squeeze-and-excitation | |
Loddo et al. | Automatic monitoring cheese ripeness using computer vision and artificial intelligence | |
Kaya et al. | An automatic identification method for the comparison of plant and honey pollen based on GLCM texture features and artificial neural network | |
CN106338488A (en) | Method for fast undamaged determination of transgenic soybean milk powder | |
CN201041547Y (en) | Device for analyzing and recognizing different types of green teas based on multi-spectrum image texture | |
Zou et al. | Identification of tea diseases based on spectral reflectance and machine learning | |
CN107255624A (en) | A kind of fast and convenient method for determining protein content in fan's power mushroom entity | |
CN114331474A (en) | Milk producing area tracing method based on fuzzy linear discriminant analysis | |
CN107561031A (en) | Based on two-dimentional near-infrared, in infrared Correlated Spectroscopy information fusion sesame oil in mix corn oil detection method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | 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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170531 |