CN105224960A - Based on the corn seed classification hyperspectral imagery model of cognition update method of clustering algorithm - Google Patents

Based on the corn seed classification hyperspectral imagery model of cognition update method of clustering algorithm Download PDF

Info

Publication number
CN105224960A
CN105224960A CN201510741678.XA CN201510741678A CN105224960A CN 105224960 A CN105224960 A CN 105224960A CN 201510741678 A CN201510741678 A CN 201510741678A CN 105224960 A CN105224960 A CN 105224960A
Authority
CN
China
Prior art keywords
identified
corn seed
corn
sample
samples
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.)
Granted
Application number
CN201510741678.XA
Other languages
Chinese (zh)
Other versions
CN105224960B (en
Inventor
黄敏
何楚婕
朱启兵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Jiangnan University
Original Assignee
Jiangnan University
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Jiangnan University filed Critical Jiangnan University
Priority to CN201510741678.XA priority Critical patent/CN105224960B/en
Publication of CN105224960A publication Critical patent/CN105224960A/en
Application granted granted Critical
Publication of CN105224960B publication Critical patent/CN105224960B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2411Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on the proximity to a decision surface, e.g. support vector machines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2413Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on distances to training or reference patterns

Landscapes

  • Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Image Analysis (AREA)

Abstract

本发明公开了基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,包括:基于采集所有待识别玉米种子在N个波段下的N个高光谱图像,计算感兴趣区域内的光谱均值特征,作为特征参数,依次输入数据,计算待识别玉米种子与检测模型的匹配性;判断匹配性,若匹配不成功,则通过化学分析测试,获得待识别玉米种子的类别,利用获得的待识别种子特征参数及其真实类别,更新训练集;在完成所有待识别玉米种子的匹配性判断后,利用新的训练集来建立新的最小二乘支持向量机检测模型fLS-SVM,用fLS-SVM来识别更新后的待识别样本集。本发明提供了一种基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,能够实现高光谱图像分类模型的更新,效果好,且可靠性高。

The invention discloses a method for updating a classification and recognition model of a corn seed hyperspectral image based on a clustering algorithm, comprising: calculating the spectral mean value feature in an area of interest based on collecting N hyperspectral images of all corn seeds to be identified under N bands , as characteristic parameters, input data in turn, calculate the matching between the corn seeds to be identified and the detection model; judge the matching, if the matching is unsuccessful, obtain the category of the corn seeds to be identified through chemical analysis tests, and use the obtained seeds to be identified Feature parameters and their true categories, update the training set; after completing the matching judgment of all corn seeds to be identified, use the new training set to establish a new least squares support vector machine detection model f LS-SVM , use f LS- SVM to identify the updated sample set to be identified. The invention provides a method for updating a hyperspectral image classification and recognition model of corn seeds based on a clustering algorithm, which can realize the update of the hyperspectral image classification model with good effect and high reliability.

Description

基于聚类算法的玉米种子高光谱图像分类识别模型更新方法A clustering algorithm-based update method for corn seed hyperspectral image classification and recognition model

技术领域technical field

本发明涉及一种玉米种子高光谱图像分类模型的更新方法,尤其是一种基于聚类算法的玉米种子高光谱图像分类识别模型更新方法。The invention relates to a method for updating a corn seed hyperspectral image classification model, in particular to a method for updating a corn seed hyperspectral image classification recognition model based on a clustering algorithm.

背景技术Background technique

近年来,随着种子杂交技术的广泛应用,种子的品种越来越多,类间相似性越来越大,混杂现象日趋严重,这导致品种区分越来越困难,种子的纯度问题也越来越受到人们的关注。种子的纯度反映种子质量的重要参数,是评定种子等级的主要依据。传统的种子纯度检测方法存在着鉴定时间长、人员依赖性强、对种子具有破坏性等缺点,难以在实际应用中得到推广。为了提高种子检测的快速性,机器视觉技术、近红外光谱分析技术以及高光谱图像技术这类的无损检测技术得到发展。机器视觉技术主要是利用种子外在形态学信息,而近红外光谱技术是利用种子中所有有机分子含氢基团的化学特征信息。无论是机器视觉技术还是近红外光谱分析技术都只能获得种子的单一性状信息,对于某些种子来说,不同品种间的某些性状信息差异并不明显,如果仅仅依赖于这些单一性状信息,会降低种子纯度检测的准确性。相比较,高光谱图像技术可以提供包含被测对象外在形态学特征,内部结构特征和化学成分特征的所有信息,这些信息为种子纯度的准确检测提供了充分可靠的信息保证。因而高光谱图像技术在农产品无损检测中得到广泛的应用。In recent years, with the wide application of seed hybridization technology, there are more and more varieties of seeds, the similarity between classes is getting bigger and bigger, and the phenomenon of mixing is becoming more and more serious, which makes it more and more difficult to distinguish varieties and the purity of seeds. more people's attention. Seed purity reflects an important parameter of seed quality and is the main basis for evaluating seed grades. The traditional method of testing the purity of seeds has the disadvantages of long identification time, strong dependence on personnel, and destructive to seeds, so it is difficult to be popularized in practical applications. In order to improve the rapidity of seed detection, non-destructive testing technologies such as machine vision technology, near-infrared spectral analysis technology and hyperspectral image technology have been developed. Machine vision technology mainly uses the external morphological information of seeds, while near-infrared spectroscopy technology uses the chemical feature information of hydrogen-containing groups of all organic molecules in seeds. Both machine vision technology and near-infrared spectral analysis technology can only obtain single trait information of seeds. For some seeds, the difference of certain trait information between different varieties is not obvious. If only relying on these single trait information, It will reduce the accuracy of seed purity detection. In comparison, hyperspectral image technology can provide all information including the external morphological characteristics, internal structural characteristics and chemical composition characteristics of the measured object, which provides sufficient and reliable information guarantee for the accurate detection of seed purity. Therefore, hyperspectral image technology has been widely used in non-destructive testing of agricultural products.

利用高光谱图像技术进行种子纯度检测从本质上来说是个模式分类问题,其分类精度受到分类特征信息的充分性、可靠性和有效性影响。因此模型更新对于提高模型的鲁棒性和泛化能力具有重要的意义。以往的学者提出的模型更新方法选择大量样本来更新模型,这种方式虽然能达到比较高的精度,但是费时费力。因此,寻找一种能选择代表性样本的模型更新策略实现种子分类模型的更新就显得尤为重要。Seed purity detection using hyperspectral image technology is essentially a pattern classification problem, and its classification accuracy is affected by the sufficiency, reliability and effectiveness of classification feature information. Therefore, model updating is of great significance to improve the robustness and generalization ability of the model. The model update method proposed by previous scholars selects a large number of samples to update the model. Although this method can achieve relatively high accuracy, it is time-consuming and laborious. Therefore, it is particularly important to find a model update strategy that can select representative samples to update the seed classification model.

发明内容Contents of the invention

本发明的目的是克服以上技术的缺点,提供一种基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其能够实现高光谱图像分类模型更新,省时省力,快速有效,且可靠性高。The purpose of the present invention is to overcome the shortcomings of the above technologies, and provide a method for updating the classification and recognition model of corn seed hyperspectral images based on clustering algorithms, which can realize the update of hyperspectral image classification models, save time and effort, be fast and effective, and have high reliability. high.

本发明提供的技术方案,所述的聚类算法的玉米种子高光谱图像分类识别模型更新方法,具体的步骤包括:a、将待识别的玉米种子样本放置在高光谱图像采集系统中,采集并获取所有玉米种子样本在N个波段下的N个高光谱图像;b、计算感兴趣区域内的光谱均值特征,将所有玉米种子的N个波段下获得的共N个光谱均值特征作为待识别玉米种子的特征参数矩阵Y;c、将步骤b所得到的玉米种子特征参数矩阵Y,依次输入数据,计算待识别玉米种子与训练样本的匹配性;d、判断待识别玉米种子与训练样本的匹配性,若匹配不成功,则通过化学分析测试,获得待识别玉米种子的类别,利用获得的待识别种子特征参数及其真实类别,更新训练集和测试集;e、重复步骤(c-d),完成所有待识别玉米种子的匹配性判断,利用新的训练集来建立新的最小二乘支持向量机检测模型fLS-SVM,用该模型来识别更新后的待识别样本集。The technical solution provided by the present invention, the method for updating the corn seed hyperspectral image classification and recognition model of the clustering algorithm, the specific steps include: a, placing the corn seed sample to be identified in the hyperspectral image acquisition system, collecting and Obtain N hyperspectral images of all corn seed samples under N bands; b. Calculate the spectral mean features in the region of interest, and use a total of N spectral mean features obtained under N bands of all corn seeds as the corn to be identified The characteristic parameter matrix Y of the seed; c, the corn seed characteristic parameter matrix Y obtained by step b, input data successively, calculate the matching of the corn seed to be identified and the training sample; d, judge the matching of the corn seed to be identified and the training sample property, if the matching is unsuccessful, then by chemical analysis test, obtain the category of the corn seed to be identified, utilize the obtained seed feature parameter and its true category to update the training set and test set; e, repeat step (cd), complete For the matching judgment of all corn seeds to be identified, the new training set is used to establish a new least squares support vector machine detection model f LS-SVM , and this model is used to identify the updated sample set to be identified.

进一步的,在步骤b中,获得玉米种子的特征参数包括:Further, in step b, obtaining the characteristic parameters of corn seeds includes:

首先选择待识别玉米种子轮廓最清晰的图像对应的波段(在782.59nm处),利用自适应阈值分割法,获得该波段下的待识别玉米种子的轮廓曲线。将该轮廓曲线投射到N个波段上,提取N个波段在该轮廓曲线内的光谱均值作为玉米种子的分类特征参数。First, select the band corresponding to the image with the clearest outline of the corn seed to be identified (at 782.59nm), and use the adaptive threshold segmentation method to obtain the outline curve of the corn seed to be identified under this band. The contour curve is projected onto N bands, and the spectral mean value of the N bands within the contour curve is extracted as the classification characteristic parameter of corn seeds.

在步骤c中判断待识别玉米种子与训练样本的匹配性的操作包括:The operation of judging the matching between the corn seed to be identified and the training sample in step c includes:

按照步骤a、b获取h类共l个玉米种子的特征参数,并利用化学分析测试,获得其类别标签,将类别标签相同的玉米种子构建为一个子训练集合,共得到h个子集合:According to steps a and b, obtain the characteristic parameters of a total of l corn seeds of class h, and use chemical analysis and testing to obtain their category labels, construct a sub-training set of corn seeds with the same category label, and obtain h sub-sets in total:

令D=[D1,…,Di,…,Dh]为h类样本的训练集,为有ni个样本的第i类样本的子集合,T=D-Di为剔除第i类样本的子集合。对于给定的训练样本 x i j ∈ D i , x i k ∈ D i , 有类内距离和类间距离 Let D=[D 1 ,...,D i ,...,D h ] be the training set of h class samples, is a subset of samples of type i with n i samples, and T=DD i is a subset of samples of type i excluded. For a given training sample x i j ∈ D. i , x i k ∈ D. i , and within-class distance and the distance between classes

SS ii jj ,, kk == || || xx ii jj -- xx ii kk || || ,, xx ii jj ,, xx ii kk ∈∈ DD. ii ,, jj ≠≠ kk -- -- -- (( 11 ))

PP ii kk ,, sthe s == || || xx ii kk -- xx ii sthe s || || ,, xx ii kk ∈∈ DD. ii ,, xx ii sthe s ∈∈ TT ii -- -- -- (( 22 ))

其中:1≤i≤h,||||表示2范数。Among them: 1≤i≤h, |||| represents the 2 norm.

在计算第i类的K最小类内距离平均和K最小类间距离平均后,计算一个判别指标 In calculating the K-minimum intra-class distance average of the i-th class and K-minimum inter-class distance mean After that, calculate a discriminant index

ThrThr ii kk == DIDI ii kk // DWDW ii kk ,, ii == 11 ,, ...... ,, hh ,, kk == 11 ,, ...... ,, nno ii -- -- -- (( 33 ))

定义一个反映不同类样本间差异性的阈值ThiDefine a threshold Th i that reflects the difference between samples of different classes:

ThTh ii == mm ii nno kk == 11 :: nno ii (( YhrYhr ii kk )) ×× ββ -- -- -- (( 44 ))

其中β为松弛系数。对h类训练样本,得到h个阈值(Th1,…,Thi,…,Thh)。where β is the relaxation coefficient. For h class training samples, h thresholds (Th 1 ,...,Th i ,...,Th h ) are obtained.

在步骤e中,建立玉米种子的最小二乘支持向量机检测模型fLS-SVM,具体包括:In step e, the least squares support vector machine detection model f LS-SVM of corn seed is established, specifically including:

利用步骤d中获得的h类共l个玉米种子的特征参数和类别标签,通过一对多方法,构建h个子LS-SVM分类模型。其第k(1≤k≤h)个子模型的输出表达式zk(Y)为:Using the feature parameters and category labels of h categories of l corn seeds obtained in step d, construct h sub-LS-SVM classification models through a one-to-many method. The output expression z k (Y) of the kth sub-model (1≤k≤h) is:

zz kk (( YY )) == sthe s gg nno [[ ΣΣ jj == 11 ll ββ jj KK (( YY ,, YY jj )) ++ bb ]] -- -- -- (( 55 ))

其中,sgn(·)为符号函数,Y为待识别玉米种子样本的特征参数,Yj为训练集玉米种子样本的特征参数,βj和b均为待定系数。当大于等于零时,sgn(·)取值为1,表示待识别样本Y属于第k类,否则不属于。Among them, sgn( ) is a symbolic function, Y is the characteristic parameter of the corn seed sample to be identified, Y j is the characteristic parameter of the corn seed sample in the training set, and β j and b are undetermined coefficients. when When it is greater than or equal to zero, sgn(·) takes a value of 1, indicating that the sample Y to be identified belongs to the kth class, otherwise it does not.

公式(5)中βj和b的取值由下列形式给出,The values of β j and b in formula (5) are given by the following forms,

00 -- DD. DD. TT ΩΩ ++ γγ -- 11 EE. bb θθ == 00 II -- -- -- (( 66 ))

其中,θ=[β1…βj…βl]和b为待求解参数;D=[d1…dj…dl],当训练样本Yj属于第k类时,dj=1,否则dj=-1。γ为为惩罚系数,E为l×l的单位方阵,I为l×1的全1列向量;Ω是l×l的方阵,其第i行第j列的元素Ωij=didjK(Yi,Yj),核函数选取:Among them, θ=[β 1 ... β j ... β l ] and b are the parameters to be solved; D = [d 1 ... d j ... d l ], when the training sample Y j belongs to the kth class, d j = 1, Otherwise d j =-1. γ is the penalty coefficient, E is the unit square matrix of l×l, and I is the vector of all 1 columns of l×1; Ω is the square matrix of l×l, and the element Ω ij =d i of the i-th row and the j-th column d j K(Y i ,Y j ), kernel function Select:

KK (( YY ii kk ,, YY jj kk )) == expexp (( -- || || YY ii kk -- YY jj kk || || 22 22 σσ 22 )) -- -- -- (( 77 ))

高斯核函数K(Y,Yi)的核宽度参数和惩罚系数γ通过网格搜索方法获得。The kernel width parameter and penalty coefficient γ of Gaussian kernel function K(Y,Y i ) are obtained by grid search method.

进一步地,基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其特征在于步骤d中判断待识别玉米种子与训练样本的匹配性,具体包括:Further, the corn seed hyperspectral image classification and recognition model update method based on clustering algorithm is characterized in that judging the matching between the corn seed to be identified and the training sample in step d, specifically including:

取一个待识别样本x,假设其属于第i类,则按式(1),(2)和(3)计算其判别指标Thri,如果Thri≥Thi,则该待识别样本与所假设的第i类样本不匹配,此时将该待识别样本归为更新样本,并利用化学分析测试,获得其类别标签,利用获得的待识别种子特征参数及其真实类别,更新训练集;反之,不更新训练集。Take a sample x to be identified, assuming it belongs to the i-th category, then calculate its discriminant indicator Thr i according to formulas (1), (2) and (3), if Thr i ≥ Th i , then the sample to be identified is consistent with the hypothesized The i-th sample does not match, at this time, the sample to be identified is classified as an update sample, and its category label is obtained by chemical analysis test, and the training set is updated by using the obtained seed feature parameters and its true category to be identified; otherwise, The training set is not updated.

附图说明Description of drawings

图1为本发明提供的基于聚类算法的玉米种子高光谱图像分类识别模型更新方法的流程图。Fig. 1 is a flowchart of a method for updating a classification and recognition model of corn seed hyperspectral images based on a clustering algorithm provided by the present invention.

具体实施方法Specific implementation method

下面结合具体附图和优选实施例对本发明做进一步说明。The present invention will be further described below in combination with specific drawings and preferred embodiments.

图1为本发明提供的基于聚类算法的玉米种子高光谱图像分类识别模型更新方法的流程图,如图1所示,其中,基于最小二乘支持向量机的模型更新具体步骤包括:a、将待识别的玉米种子样本放置在高光谱图像采集系统中,采集并获取所有玉米种子样本在N个波段下的N个高光谱图像;b、计算感兴趣区域内的光谱均值特征,将所有玉米种子的N个波段下获得的共N个光谱均值特征作为待识别玉米种子的特征参数矩阵Y;c、将步骤b所得到的玉米种子特征参数矩阵Y,依次输入数据,计算待识别玉米种子与训练样本的匹配性;d、判断待识别玉米种子与训练样本的匹配性,若匹配不成功,则通过化学分析测试,获得待识别玉米种子的类别,利用获得的待识别种子特征参数及其真实类别,更新训练集和测试集;e、重复步骤(c-d),完成所有待识别玉米种子的匹配性判断,利用新的训练集来建立新的最小二乘支持向量机检测模型fLS-SVM,用该模型来识别更新后的待识别样本集。Fig. 1 is the flow chart of the corn seed hyperspectral image classification recognition model updating method based on clustering algorithm provided by the present invention, as shown in Fig. 1, wherein, based on the model update specific steps of least squares support vector machine comprising: a, Place the corn seed samples to be identified in the hyperspectral image acquisition system, collect and obtain N hyperspectral images of all corn seed samples in N bands; A total of N spectral mean features obtained under the N bands of the seed are used as the characteristic parameter matrix Y of the corn seed to be identified; c, the corn seed characteristic parameter matrix Y obtained in step b, is input data in turn, and the calculated corn seed to be identified and The matching of the training samples; d, judging the matching of the corn seeds to be identified and the training samples, if the matching is unsuccessful, the chemical analysis test is used to obtain the category of the corn seeds to be identified, and the obtained characteristic parameters of the seeds to be identified and their true Category, update training set and test set; e, repeat step (cd), complete the matching judgment of all corn seeds to be identified, utilize new training set to set up new least squares support vector machine detection model f LS-SVM , Use this model to identify the updated sample set to be identified.

进一步的,在步骤b中,获得玉米种子的特征参数包括:Further, in step b, obtaining the characteristic parameters of corn seeds includes:

首先选择待识别玉米种子轮廓最清晰的图像对应的波段(在782.59nm处),利用自适应阈值分割法,获得该波段下的待识别玉米种子的轮廓曲线。将该轮廓曲线投射到N个波段上,提取N个波段在该轮廓曲线内的光谱均值作为玉米种子的分类特征参数。First, select the band corresponding to the image with the clearest outline of the corn seed to be identified (at 782.59nm), and use the adaptive threshold segmentation method to obtain the outline curve of the corn seed to be identified under this band. The contour curve is projected onto N bands, and the spectral mean value of the N bands within the contour curve is extracted as the classification characteristic parameter of corn seeds.

在步骤c中计算待识别玉米种子与训练样本的匹配性的操作包括:The operation of calculating the matching between the corn seed to be identified and the training sample in step c includes:

按照步骤a、b获取h类共l个玉米种子的特征参数,并利用化学分析测试,获得其类别标签,将类别标签相同的玉米种子构建为一个子训练集合,共得到h个子集合:According to steps a and b, obtain the characteristic parameters of a total of l corn seeds of class h, and use chemical analysis and testing to obtain their category labels, construct a sub-training set of corn seeds with the same category label, and obtain h sub-sets in total:

令D=[D1,…,Di,…,Dh]为h类样本的训练集,为有ni个样本的第i类样本的子集合,T=D-Di为剔除第i类样本的子集合。对于给定的训练样本 x i j ∈ D i , x i k ∈ D i , x i s ∈ T i , 有类内距离和类间距离 Let D=[D 1 ,...,D i ,...,D h ] be the training set of h class samples, is a subset of samples of type i with n i samples, and T=DD i is a subset of samples of type i excluded. For a given training sample x i j ∈ D. i , x i k ∈ D. i , and x i the s ∈ T i , within-class distance and the distance between classes

SS ii jj ,, kk == || || xx ii jj -- xx ii kk || || ,, xx ii jj ,, xx ii kk ∈∈ DD. ii ,, jj ≠≠ kk -- -- -- (( 11 ))

PP ii kk ,, sthe s == || || xx ii kk -- xx ii sthe s || || ,, xx ii kk ∈∈ DD. ii ,, xx ii sthe s ∈∈ TT ii -- -- -- (( 22 ))

其中:1≤i≤h,||||表示2范数。Among them: 1≤i≤h, |||| represents the 2 norm.

在计算第i类的K最小类内距离平均和K最小类间距离平均后,计算一个判别指标 In calculating the K-minimum intra-class distance average of the i-th class and K-minimum inter-class distance mean After that, calculate a discriminant index

ThrThr ii kk == DIDI ii kk // DWDW ii kk ,, ii == 11 ,, ...... ,, hh ,, kk == 11 ,, ...... ,, nno ii -- -- -- (( 33 ))

定义一个反映不同类样本间差异性的阈值ThiDefine a threshold Th i that reflects the difference between samples of different classes:

ThTh ii == mm ii nno kk == 11 :: nno ii (( ThrThr ii kk )) ×× ββ -- -- -- (( 44 ))

其中β为松弛系数。对h类训练样本,得到h个阈值(Th1,…,Thi,…,Thh)。where β is the relaxation coefficient. For h class training samples, h thresholds (Th 1 ,...,Th i ,...,Th h ) are obtained.

在步骤e中,建立玉米种子的最小二乘支持向量机检测模型fLS-SVM,具体包括:In step e, the least squares support vector machine detection model f LS-SVM of corn seed is established, specifically including:

利用步骤d中获得的h类共l个玉米种子的特征参数和类别标签,通过一对多方法,构建h个子LS-SVM分类模型。其第k(1≤k≤h)个子模型的输出表达式zk(Y)为:Using the feature parameters and category labels of h categories of l corn seeds obtained in step d, construct h sub-LS-SVM classification models through a one-to-many method. The output expression z k (Y) of the kth sub-model (1≤k≤h) is:

zz kk (( YY )) == sthe s gg nno [[ ΣΣ jj == 11 ll ββ jj KK (( YY ,, YY jj )) ++ bb ]] -- -- -- (( 55 ))

其中,sgn(·)为符号函数,Y为待识别玉米种子样本的特征参数,Yj为训练集玉米种子样本的特征参数,βj和b均为待定系数。当大于等于零时,sgn(·)取值为1,表示待识别样本Y属于第k类,否则不属于。Among them, sgn( ) is a symbolic function, Y is the characteristic parameter of the corn seed sample to be identified, Y j is the characteristic parameter of the corn seed sample in the training set, and β j and b are undetermined coefficients. when When it is greater than or equal to zero, sgn(·) takes a value of 1, indicating that the sample Y to be identified belongs to the kth class, otherwise it does not.

公式(5)中βj和b的取值由下列形式给出,The values of β j and b in formula (5) are given by the following forms,

00 -- DD. DD. TT ΩΩ ++ γγ -- 11 EE. bb θθ == 00 II -- -- -- (( 66 ))

其中,θ=[β1…βj…βl]和b为待求解参数;D=[d1…dj…dl],当训练样本Yj属于第k类时,dj=1,否则dj=-1。γ为为惩罚系数,E为l×l的单位方阵,I为l×1的全1列向量;Ω是l×l的方阵,其第i行第j列的元素Ωij=didjK(Yi,Yj),核函数选取:Among them, θ=[β 1 ... β j ... β l ] and b are the parameters to be solved; D = [d 1 ... d j ... d l ], when the training sample Y j belongs to the kth class, d j = 1, Otherwise d j =-1. γ is the penalty coefficient, E is the unit square matrix of l×l, and I is the vector of all 1 columns of l×1; Ω is the square matrix of l×l, and the element Ω ij =d i of the i-th row and the j-th column d j K(Y i ,Y j ), kernel function Select:

KK (( YY ii kk ,, YY jj kk )) == expexp (( -- || || YY ii kk -- YY jj kk || || 22 22 σσ 22 )) -- -- -- (( 77 ))

高斯核函数K(Y,Yi)的核宽度参数和惩罚系数γ通过网格搜索方法获得。The kernel width parameter and penalty coefficient γ of Gaussian kernel function K(Y,Y i ) are obtained by grid search method.

进一步地,基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其特征在于步骤d中判断待识别玉米种子与训练样本的匹配性,具体包括:Further, the corn seed hyperspectral image classification and recognition model update method based on clustering algorithm is characterized in that judging the matching between the corn seed to be identified and the training sample in step d, specifically including:

取一个待识别样本x,假设其属于第i类,则按式(1),(2)和(3)计算其判别指标Thri,如果Thri≥Thi,则该待识别样本与所假设的第i类样本不匹配,此时将该待识别样本归为更新样本,并利用化学分析测试,获得其类别标签,利用获得的待识别种子特征参数及其真实类别,更新训练集;反之,不更新训练集。Take a sample x to be identified, assuming it belongs to the i-th category, then calculate its discriminant indicator Thr i according to formulas (1), (2) and (3), if Thr i ≥ Th i , then the sample to be identified is consistent with the hypothesized The i-th sample does not match, at this time, the sample to be identified is classified as an update sample, and its category label is obtained by chemical analysis test, and the training set is updated by using the obtained seed feature parameters and its true category to be identified; otherwise, The training set is not updated.

本发明的优势:提供一种基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其能够实现高光谱图像分类模型更新,省时省力,快速有效,且可靠性高。Advantages of the present invention: provide a method for updating a hyperspectral image classification and recognition model of corn seeds based on a clustering algorithm, which can realize the update of a hyperspectral image classification model, saves time and effort, is fast and effective, and has high reliability.

Claims (2)

1.基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其特征在于,包括:1. the corn seed hyperspectral image classification recognition model updating method based on clustering algorithm, it is characterized in that, comprises: a、将待识别的玉米种子样本放置在高光谱图像采集系统中,采集并获取所有玉米种子样本在N个波段下的N个高光谱图像;a. Place the corn seed samples to be identified in the hyperspectral image acquisition system, collect and obtain N hyperspectral images of all corn seed samples in N bands; b、计算感兴趣区域内的光谱均值特征,将所有玉米种子的N个波段下获得的共N个光谱均值特征作为待识别玉米种子的特征参数矩阵Y;B, calculate the spectral mean value feature in the region of interest, and the total N spectral mean value features obtained under the N bands of all corn seeds are used as the characteristic parameter matrix Y of the corn seed to be identified; c、将步骤b所得到的玉米种子特征参数矩阵Y,依次输入数据,计算待识别玉米种子与训练样本的匹配性;C, the corn seed characteristic parameter matrix Y that step b is obtained, input data successively, calculate the matching of the corn seed to be identified and the training sample; d、判断待识别玉米种子与训练样本的匹配性,若匹配不成功,则通过化学分析测试,获得待识别玉米种子的类别,利用获得的待识别种子特征参数及其真实类别,更新训练集和测试集;d. Judging the matching between the corn seeds to be identified and the training samples, if the matching is unsuccessful, the category of the corn seeds to be identified is obtained through a chemical analysis test, and the training set and test set; e、重复步骤(c-d),完成所有待识别玉米种子的匹配性判断,利用新的训练集来建立新的最小二乘支持向量机检测模型fLS-SVM,用该模型来识别更新后的待识别样本集。e, repeat step (cd), complete the matching judgment of all corn seeds to be identified, use the new training set to set up a new least squares support vector machine detection model f LS-SVM , and use this model to identify the updated corn seeds Identify sample sets. 在步骤b中,获得玉米种子的特征参数包括:In step b, obtaining the characteristic parameter of corn seed comprises: 首先选择待识别玉米种子轮廓最清晰的图像对应的波段(在782.59nm处),利用自适应阈值分割法,获得该波段下的待识别玉米种子的轮廓曲线。将该轮廓曲线投射到N个波段上,提取N个波段在该轮廓曲线内的光谱均值作为玉米种子的分类特征参数。First, select the band corresponding to the image with the clearest outline of the corn seed to be identified (at 782.59nm), and use the adaptive threshold segmentation method to obtain the outline curve of the corn seed to be identified under this band. The profile curve is projected onto N bands, and the spectral mean value of the N bands within the profile curve is extracted as the classification characteristic parameter of corn seeds. 在步骤c中计算待识别玉米种子与训练样本的匹配性的操作包括:The operation of calculating the matching between the corn seed to be identified and the training sample in step c includes: 按照步骤a、b获取h类共l个玉米种子的特征参数,并利用化学分析测试,获得其类别标签,将类别标签相同的玉米种子构建为一个子训练集合,共得到h个子集合:According to steps a and b, obtain the characteristic parameters of a total of l corn seeds of class h, and use chemical analysis and testing to obtain their category labels, construct a sub-training set of corn seeds with the same category label, and obtain h sub-sets in total: 令D=[D1,…,Di,…,Dh]为h类样本的训练集,为有ni个样本的第i类样本的子集合,T=D-Di为剔除第i类样本的子集合。对于给定的训练样本有类内距离和类间距离 Let D=[D 1 ,...,D i ,...,D h ] be the training set of h class samples, is a subset of samples of type i with n i samples, and T=DD i is a subset of samples of type i excluded. For a given training sample and within-class distance and the distance between classes SS ii jj ,, kk == || || xx ii jj -- xx ii kk || || ,, xx ii jj ,, xx ii kk ∈∈ DD. ii ,, jj ≠≠ kk -- -- -- (( 11 )) PP ii kk ,, sthe s == || || xx ii kk -- xx ii sthe s || || ,, xx ii kk ∈∈ DD. ii ,, xx ii sthe s ∈∈ TT ii -- -- -- (( 22 )) 其中:1≤i≤h,||||表示2范数。Among them: 1≤i≤h, |||| represents the 2 norm. 在计算第i类的K最小类内距离平均和K最小类间距离平均后,计算一个判别指标 In calculating the K-minimum intra-class distance average of the i-th class and K-minimum inter-class distance mean After that, calculate a discriminant index ThrThr ii kk == DIDI ii kk // DWDW ii kk ,, ii == 11 ,, ...... ,, hh ,, kk == 11 ,, ...... ,, nno ii -- -- -- (( 33 )) 定义一个反映不同类样本间差异性的阈值ThiDefine a threshold Th i that reflects the difference between samples of different classes: ThTh ii == mm ii nno kk == 11 :: nno ii (( YhrYhr ii kk )) ×× ββ -- -- -- (( 44 )) 其中β为松弛系数。对h类训练样本,得到h个阈值(Th1,…,Thi,…,Thh)。where β is the relaxation coefficient. For h class training samples, h thresholds (Th 1 ,...,Th i ,...,Th h ) are obtained. 在步骤e中,建立玉米种子的最小二乘支持向量机检测模型fLS-SVM,具体包括:In step e, the least squares support vector machine detection model f LS-SVM of corn seed is established, specifically including: 利用步骤d中获得的h类共l个玉米种子的特征参数和类别标签,通过一对多方法,构建h个子LS-SVM分类模型。其第k(1≤k≤h)个子模型的输出表达式zk(Y)为:Using the feature parameters and category labels of h categories of l corn seeds obtained in step d, construct h sub-LS-SVM classification models through a one-to-many method. The output expression z k (Y) of the kth sub-model (1≤k≤h) is: z k ( Y ) = s g n [ Σ j = 1 l β j K ( Y , Y j ) + b ] - - - ( 5 ) 其中,sgn(·)为符号函数,Y为待识别玉米种子样本的特征参数,Yj为训练集玉米种子样本的特征参数,βj和b均为待定系数。当大于等于零时,sgn(·)取值为1,表示待识别样本Y属于第k类,否则不属于。 z k ( Y ) = the s g no [ Σ j = 1 l β j K ( Y , Y j ) + b ] - - - ( 5 ) Among them, sgn( ) is a symbolic function, Y is the characteristic parameter of the corn seed sample to be identified, Y j is the characteristic parameter of the corn seed sample in the training set, and β j and b are undetermined coefficients. when When it is greater than or equal to zero, sgn(·) takes a value of 1, indicating that the sample Y to be identified belongs to the kth class, otherwise it does not. 公式(5)中βj和b的取值由下列形式给出,The values of β j and b in formula (5) are given by the following forms, 00 -- DD. DD. TT ΩΩ ++ γγ -- 11 EE. bb θθ == 00 II -- -- -- (( 66 )) 其中,θ=[β1…βj…βl]和b为待求解参数;D=[d1…dj…dl],当训练样本Yj属于第k类时,dj=1,否则dj=-1。γ为为惩罚系数,E为l×l的单位方阵,I为l×1的全1列向量;Ω是l×l的方阵,其第i行第j列的元素Ωij=didjK(Yi,Yj),核函数选取:Among them, θ=[β 1 ... β j ... β l ] and b are the parameters to be solved; D = [d 1 ... d j ... d l ], when the training sample Y j belongs to the kth class, d j = 1, Otherwise d j =-1. γ is the penalty coefficient, E is the unit square matrix of l×l, and I is the vector of all 1 columns of l×1; Ω is the square matrix of l×l, and the element Ω ij =d i of the i-th row and the j-th column d j K(Y i ,Y j ), kernel function Select: KK (( YY ii kk ,, YY jj kk )) == expexp (( -- || || YY ii kk -- YY jj kk || || 22 22 σσ 22 )) -- -- -- (( 77 )) 高斯核函数K(Y,Yi)的核宽度参数和惩罚系数γ通过网格搜索方法获得。The kernel width parameter and penalty coefficient γ of Gaussian kernel function K(Y,Y i ) are obtained by grid search method. 2.权利要求1所述的基于聚类算法的玉米种子高光谱图像分类识别模型更新方法,其特征在于步骤d中判断待识别玉米种子与训练样本的匹配性判断,具体包括:2. the corn seed hyperspectral image classification recognition model updating method based on clustering algorithm according to claim 1, is characterized in that judging the matching judgment of corn seed to be identified and training sample in the step d, specifically comprises: 取一个待识别样本x,假设其属于第i类,则按式(1),(2)和(3)计算其判别指标Thri,如果Thri≥Thi,则该待识别样本与所假设的第i类样本不匹配,此时将该待识别样本归为更新样本,并利用化学分析测试,获得其类别标签,利用获得的待识别种子特征参数及其真实类别,更新训练集;反之,不更新训练集。Take a sample x to be identified, assuming it belongs to the i-th category, then calculate its discriminant indicator Thr i according to formulas (1), (2) and (3), if Thr i ≥ Th i , then the sample to be identified is consistent with the hypothesized The i-th sample does not match, at this time, the sample to be identified is classified as an update sample, and its category label is obtained by chemical analysis test, and the training set is updated by using the obtained seed feature parameters and its true category to be identified; otherwise, The training set is not updated.
CN201510741678.XA 2015-11-04 2015-11-04 Corn seed classification hyperspectral imagery identification model update method based on clustering algorithm Active CN105224960B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510741678.XA CN105224960B (en) 2015-11-04 2015-11-04 Corn seed classification hyperspectral imagery identification model update method based on clustering algorithm

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510741678.XA CN105224960B (en) 2015-11-04 2015-11-04 Corn seed classification hyperspectral imagery identification model update method based on clustering algorithm

Publications (2)

Publication Number Publication Date
CN105224960A true CN105224960A (en) 2016-01-06
CN105224960B CN105224960B (en) 2018-07-20

Family

ID=54993920

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510741678.XA Active CN105224960B (en) 2015-11-04 2015-11-04 Corn seed classification hyperspectral imagery identification model update method based on clustering algorithm

Country Status (1)

Country Link
CN (1) CN105224960B (en)

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106546541A (en) * 2016-10-31 2017-03-29 浙江大学 A kind of identifying device and method based on EO-1 hyperion transgenic corns seed
CN106613913A (en) * 2016-12-23 2017-05-10 天津农学院 Near infrared-intermediate infrared rapid selection method for corn inbred line combination selection
CN106841054A (en) * 2017-01-04 2017-06-13 江南大学 Seed variety recognition methods and device
CN107679222A (en) * 2017-10-20 2018-02-09 广东欧珀移动通信有限公司 Image processing method, mobile terminal and computer-readable recording medium
CN107862335A (en) * 2017-11-07 2018-03-30 河南科技大学 A kind of texture image classification method based on multiple dimensioned feedback metric learning
CN108229566A (en) * 2018-01-05 2018-06-29 厦门华联电子股份有限公司 A kind of hierarchy sorting technique and device
CN108444928A (en) * 2018-03-12 2018-08-24 浙江大学 A method of identifying cereal seed frostbite situation using embryo chromatogram characteristic wave band
CN108920863A (en) * 2018-07-20 2018-11-30 湖南大学 A kind of method for building up of robot servo system energy consumption estimation model
CN110008948A (en) * 2019-04-15 2019-07-12 西安电子科技大学 Target detection method in hyperspectral image based on variational autoencoder network
CN110837823A (en) * 2019-12-17 2020-02-25 华南农业大学 Method for generating seed variety identification model, identification method and device
CN111738287A (en) * 2020-04-03 2020-10-02 南京林业大学 Masson pine seed activity detection system and detection method based on multimodal information fusion
CN112147083A (en) * 2020-10-14 2020-12-29 武汉轻工大学 Seed purity detection method, detection device and computer readable storage medium
CN114723751A (en) * 2022-06-07 2022-07-08 中国空气动力研究与发展中心设备设计与测试技术研究所 Unsupervised strip steel surface defect online detection method
CN116228759A (en) * 2023-05-08 2023-06-06 浙江大学滨江研究院 Computer-aided diagnosis system and apparatus for renal cell carcinoma type

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080118124A1 (en) * 2006-10-18 2008-05-22 Anant Madabhushi Systems and methods for classification of biological datasets
CN101540048B (en) * 2009-04-21 2010-08-11 北京航空航天大学 Image quality evaluating method based on support vector machine
CN104990892A (en) * 2015-06-24 2015-10-21 中国农业大学 Spectrum image lossless identification model establishing method for seeds and seed identification method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080118124A1 (en) * 2006-10-18 2008-05-22 Anant Madabhushi Systems and methods for classification of biological datasets
CN101540048B (en) * 2009-04-21 2010-08-11 北京航空航天大学 Image quality evaluating method based on support vector machine
CN104990892A (en) * 2015-06-24 2015-10-21 中国农业大学 Spectrum image lossless identification model establishing method for seeds and seed identification method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
朱启兵 等: "基于高光谱图像技术和SVDD的玉米种子识别", 《光谱学与光谱分析》 *

Cited By (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106546541A (en) * 2016-10-31 2017-03-29 浙江大学 A kind of identifying device and method based on EO-1 hyperion transgenic corns seed
CN106613913B (en) * 2016-12-23 2018-07-20 天津农学院 Infrared rapid screening method in the near-infrared-of corn inbred line combination selection
CN106613913A (en) * 2016-12-23 2017-05-10 天津农学院 Near infrared-intermediate infrared rapid selection method for corn inbred line combination selection
CN106841054B (en) * 2017-01-04 2019-06-07 江南大学 Seed variety recognition methods and device
CN106841054A (en) * 2017-01-04 2017-06-13 江南大学 Seed variety recognition methods and device
CN107679222A (en) * 2017-10-20 2018-02-09 广东欧珀移动通信有限公司 Image processing method, mobile terminal and computer-readable recording medium
CN107862335A (en) * 2017-11-07 2018-03-30 河南科技大学 A kind of texture image classification method based on multiple dimensioned feedback metric learning
CN108229566A (en) * 2018-01-05 2018-06-29 厦门华联电子股份有限公司 A kind of hierarchy sorting technique and device
CN108229566B (en) * 2018-01-05 2020-06-05 厦门华联电子股份有限公司 Hierarchical classification method and device
CN108444928A (en) * 2018-03-12 2018-08-24 浙江大学 A method of identifying cereal seed frostbite situation using embryo chromatogram characteristic wave band
CN108444928B (en) * 2018-03-12 2020-10-09 浙江大学 A method for identifying frostbite of grain seeds by using characteristic bands of seed embryo spectrum
CN108920863A (en) * 2018-07-20 2018-11-30 湖南大学 A kind of method for building up of robot servo system energy consumption estimation model
CN108920863B (en) * 2018-07-20 2021-02-09 湖南大学 A method for establishing energy consumption estimation model of robot servo system
CN110008948A (en) * 2019-04-15 2019-07-12 西安电子科技大学 Target detection method in hyperspectral image based on variational autoencoder network
CN110837823A (en) * 2019-12-17 2020-02-25 华南农业大学 Method for generating seed variety identification model, identification method and device
CN111738287A (en) * 2020-04-03 2020-10-02 南京林业大学 Masson pine seed activity detection system and detection method based on multimodal information fusion
CN111738287B (en) * 2020-04-03 2021-03-26 南京林业大学 Masson pine seed activity detection system and detection method based on multimodal information fusion
CN112147083A (en) * 2020-10-14 2020-12-29 武汉轻工大学 Seed purity detection method, detection device and computer readable storage medium
CN112147083B (en) * 2020-10-14 2023-07-11 武汉轻工大学 Seed purity detection method, detection device and computer readable storage medium
CN114723751A (en) * 2022-06-07 2022-07-08 中国空气动力研究与发展中心设备设计与测试技术研究所 Unsupervised strip steel surface defect online detection method
CN114723751B (en) * 2022-06-07 2022-09-23 中国空气动力研究与发展中心设备设计与测试技术研究所 Unsupervised strip steel surface defect online detection method
CN116228759A (en) * 2023-05-08 2023-06-06 浙江大学滨江研究院 Computer-aided diagnosis system and apparatus for renal cell carcinoma type

Also Published As

Publication number Publication date
CN105224960B (en) 2018-07-20

Similar Documents

Publication Publication Date Title
CN105224960B (en) Corn seed classification hyperspectral imagery identification model update method based on clustering algorithm
CN102788752B (en) Non-destructive detection device and method of internal information of crops based on spectrum technology
CN105117734B (en) Corn seed classification hyperspectral imagery recognition methods based on model online updating
CN104866871B (en) Hyperspectral image classification method based on projection structure sparse coding
CN104820841B (en) Hyperspectral classification method based on low order mutual information and spectrum context waveband selection
CN101498661B (en) Infrared spectrum feature extraction method for high-precision distinguishing variety, producing area and growth mode of traditional Chinese medicinal material
CN105334504B (en) The radar target identification method of nonlinear discriminant projection model based on big border
CN108830243A (en) Hyperspectral image classification method based on capsule network
CN105954412B (en) For the sensor array optimization method of hickory nut freshness detection
CN104374738A (en) Qualitative analysis method for improving identification result on basis of near-infrared mode
CN110874576B (en) Pedestrian re-identification method based on typical correlation analysis fusion characteristics
CN105181650A (en) Method for quickly identifying tea varieties through near-infrared spectroscopy technology
CN107478418A (en) A kind of rotating machinery fault characteristic automatic extraction method
CN105160351A (en) Semi-monitoring high-spectral classification method based on anchor point sparse graph
CN103839075A (en) SAR image classification method based on united sparse representation
CN117197804A (en) A method for identifying tea geographical indication products
CN101127086A (en) Multiple-choice weighted classification method for hyperspectral images
CN107122799A (en) Hyperspectral image classification method based on expanding morphology and Steerable filter
CN115273072B (en) Apple Leaf Disease Detection Method Based on Improved Yolov5s Model
CN107944413A (en) Aquatic vegetation Classification in Remote Sensing Image threshold value calculation method based on spectral index ranking method
CN112465821A (en) Multi-scale pest image detection method based on boundary key point perception
CN102930291A (en) Automatic K adjacent local search heredity clustering method for graphic image
CN102621075B (en) Method for automatically detecting rice heading stage
CN108985336A (en) A kind of fruit quality classification method based on multi-layer SVM
CN106778802A (en) A kind of classification hyperspectral imagery Multiple Kernel Learning method for maximizing classification separability

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant