CN116205858A - Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium - Google Patents

Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium Download PDF

Info

Publication number
CN116205858A
CN116205858A CN202310077517.XA CN202310077517A CN116205858A CN 116205858 A CN116205858 A CN 116205858A CN 202310077517 A CN202310077517 A CN 202310077517A CN 116205858 A CN116205858 A CN 116205858A
Authority
CN
China
Prior art keywords
hyperspectral image
target
pixel
chessboard
anomaly detection
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
Application number
CN202310077517.XA
Other languages
Chinese (zh)
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.)
Aerospace Information Research Institute of CAS
Original Assignee
Aerospace Information Research Institute of CAS
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 Aerospace Information Research Institute of CAS filed Critical Aerospace Information Research Institute of CAS
Priority to CN202310077517.XA priority Critical patent/CN116205858A/en
Publication of CN116205858A publication Critical patent/CN116205858A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10032Satellite or aerial image; Remote sensing
    • G06T2207/10036Multispectral image; Hyperspectral image
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A40/00Adaptation technologies in agriculture, forestry, livestock or agroalimentary production
    • Y02A40/10Adaptation technologies in agriculture, forestry, livestock or agroalimentary production in agriculture

Landscapes

  • Engineering & Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)

Abstract

The invention relates to the technical field of image processing, and provides a hyperspectral image anomaly detection method, a hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and a hyperspectral image anomaly detection storage medium, wherein the hyperspectral image anomaly detection method comprises the following steps: acquiring a hyperspectral image to be processed; according to the wave band number and the pixel number of the hyperspectral image, respectively dividing rows and columns of the hyperspectral image, and constructing a checkerboard topology frame of the hyperspectral image; and determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the constructed checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected. According to the hyperspectral image anomaly detection method provided by the invention, the hyperspectral image is disassembled by constructing the checkerboard topological frame, anomaly detection is carried out on pixels to be detected one by one, the characteristics of the hyperspectral image are fully excavated, the ground feature detail information in the hyperspectral image is extracted, and the accuracy of hyperspectral image anomaly detection is improved.

Description

Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium
Technical Field
The present invention relates to the field of image processing technologies, and in particular, to a method, an apparatus, a device, and a storage medium for detecting a hyperspectral image anomaly.
Background
At present, the existing target detection algorithm based on hyperspectral images mostly originates from the field of signal processing, a mature theoretical system and various algorithms are available, and the traditional detection method based on the algorithms mostly can realize effective separation between a target and a background under the reasonable model assumption and shows a stable detection effect. However, in practical applications, hyperspectral remote sensing data are mostly obtained by imaging a real scene containing multiple types of features, and the traditional detection method depends on a specific assumption and has limited resolving power to a complex model, so that the method is often not suitable for real hyperspectral image data with complex feature distribution, and is mainly because abundant detailed information provided by hyperspectral images cannot be fully utilized, so that the detection effect is not ideal, and the detection accuracy of hyperspectral image anomalies is low.
Disclosure of Invention
The invention provides a hyperspectral image anomaly detection method, a hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and a hyperspectral image storage medium, which are used for solving the defects that the existing hyperspectral image detection mode cannot fully utilize abundant detailed information provided by a hyperspectral image, so that the hyperspectral image anomaly detection accuracy is low.
The invention provides a hyperspectral image anomaly detection method, which comprises the following steps:
acquiring a hyperspectral image to be processed;
dividing the hyperspectral image into rows and columns according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing a chessboard row of the hyperspectral image;
constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
According to the hyperspectral image anomaly detection method provided by the invention, the target anomaly score of each pixel to be detected in the hyperspectral image is determined based on the checkerboard topology frame, and the method comprises the following steps:
determining a target chessboard row corresponding to each target pixel in the hyperspectral image based on the chessboard topology frame; the target pixel is any pixel to be detected in the hyperspectral image;
Determining a target wave band distribution vector and a target base distribution vector corresponding to the target pixel according to the target chessboard;
determining a first anomaly score of the target pixel according to the target band distribution vector and the target base distribution vector;
and acquiring a mean vector of the hyperspectral image, and weighting the first anomaly score based on the mean vector to obtain a target anomaly score of the target pixel.
According to the hyperspectral image anomaly detection method provided by the invention, the first anomaly score of the target pixel is determined according to the target band distribution vector and the target base distribution vector, and the method comprises the following steps:
determining a target band number and a target base set occupied by the target pixel in the target chessboard row according to the target band distribution vector and the target base distribution vector;
taking the band number corresponding to the minimum value in the target base number set as the optimal sub-band corresponding to the target pixel;
determining a target chessboard column corresponding to the optimal sub-band in the target chessboard row and a target base corresponding to the target pixel in the target chessboard column;
Obtaining a maximum base number in the target chessboard route, and calculating the ratio of the target base number to the maximum base number;
and determining a first anomaly score of the target pixel according to the ratio.
According to the hyperspectral image anomaly detection method provided by the invention, the first anomaly score is weighted based on the mean vector, and the method comprises the following steps:
acquiring a wave band distribution vector and a base distribution vector of the mean vector on the checkerboard topology frame;
calculating a first difference vector between the band distribution vector of the mean vector and the target band distribution vector of the target pixel, and a second difference vector between the base distribution vector of the mean vector and the target base distribution vector of the target pixel;
and determining a weight value according to the first difference value vector and the second difference value vector, and carrying out weighting processing on the first anomaly score based on the weight value.
According to the hyperspectral image anomaly detection method provided by the invention, the hyperspectral image is subjected to row division according to the wave band number of the hyperspectral image, and a chessboard array of the hyperspectral image is constructed, and the method comprises the following steps:
Extracting a target image of the hyperspectral image on each wave band according to the wave band number of the hyperspectral image;
determining a first pixel value interval of pixels in the target image, performing equally-spaced column division on the target image according to the first pixel value interval, and unifying the quantity of pixels distributed in each column interval planned to be divided to obtain a base number set of a wave band corresponding to the target image;
and constructing a checkerboard column of the hyperspectral image based on the radix set.
According to the hyperspectral image anomaly detection method provided by the invention, the hyperspectral image is divided into rows according to the pixel number of the hyperspectral image, and the chessboard rows of the hyperspectral image are constructed, and the method comprises the following steps:
acquiring a second pixel value interval of a target pixel to be detected in the hyperspectral image; the target to-be-detected pixel is any to-be-detected pixel in the hyperspectral image;
performing equidistant line division on the hyperspectral image according to the second pixel value interval, and counting the band numbers and band numbers occupied by the target to-be-detected pixels in each divided line interval;
generating a wave band distribution vector of the target pixel to be detected according to the wave band number;
Based on the chessboard columns, acquiring a base set corresponding to each band number, and calculating the base sum of all base numbers in the base set;
generating a base distribution vector of the target pixel to be detected according to the base sum;
and constructing a chessboard row of the hyperspectral image based on the wave band distribution vector and the base distribution vector of the target pixel to be detected.
According to the hyperspectral image anomaly detection method provided by the invention, the anomaly detection result of the hyperspectral image is determined according to the target anomaly score of each pixel to be detected, and the method comprises the following steps:
determining abnormal pixels in the hyperspectral image according to the target abnormal score of each pixel to be detected;
and determining an abnormal detection result of the hyperspectral image according to the abnormal pixel.
The invention also provides a hyperspectral image anomaly detection device, which comprises:
the image acquisition module is used for acquiring a hyperspectral image to be processed;
the chessboard column construction module is used for dividing the hyperspectral image into columns and rows according to the wave band number of the hyperspectral image, and constructing chessboard columns of the hyperspectral image;
the chessboard line construction module is used for dividing the hyperspectral image into lines according to the pixel number of the hyperspectral image, and constructing the chessboard line of the hyperspectral image;
The chessboard frame construction module is used for constructing a chessboard topology frame of the hyperspectral image based on the chessboard columns and the chessboard rows;
the anomaly detection module is used for determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the chessboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
The invention also provides an electronic device comprising a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the hyperspectral image anomaly detection method according to any one of the above when executing the program.
The present invention also provides a non-transitory computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements a hyperspectral image anomaly detection method as described in any one of the above.
The invention also provides a computer program product comprising a computer program which when executed by a processor implements a hyperspectral image anomaly detection method as described in any one of the above.
According to the hyperspectral image anomaly detection method, the hyperspectral image anomaly detection device, the hyperspectral image anomaly detection equipment and the hyperspectral image storage medium, the hyperspectral image to be processed is obtained, the hyperspectral image is subjected to row-column division according to the wave band number and the pixel number of the hyperspectral image, and the chessboard rows and the chessboard columns of the hyperspectral image are constructed, so that a chessboard-shaped topological frame of the hyperspectral image is constructed; and determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the constructed checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected. The hyperspectral image is disassembled by constructing a checkerboard topology frame, abnormal detection is carried out on pixels to be detected one by one, characteristics of the hyperspectral image are fully excavated, ground feature detail information in the hyperspectral image is extracted, and accuracy of the hyperspectral image abnormal detection is improved.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of a hyperspectral image anomaly detection method provided by the invention;
fig. 2 is a schematic structural diagram of the hyperspectral image anomaly detection device provided by the invention;
fig. 3 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The hyperspectral image anomaly detection method, apparatus, device and storage medium of the present invention are described below with reference to fig. 1 to 3.
The hyperspectral image anomaly detection method provided by the invention is used for detecting the anomaly of the hyperspectral image, the hyperspectral image is disassembled through the chessboard topology frame, the deep features of the hyperspectral image are mined, and the ground feature detail information is extracted, so that the anomaly information is accurately separated from the background, the rich detail information provided by the hyperspectral image can be fully utilized, the limitation of the traditional detection method depending on a specific model assumption is avoided, and the anomaly detection accuracy of the hyperspectral image is improved.
Specifically, referring to fig. 1, fig. 1 is a flow chart of a method for detecting a hyperspectral image abnormality according to the present invention, and based on fig. 1, the method for detecting a hyperspectral image abnormality according to the present invention includes:
step 100, obtaining a hyperspectral image to be processed;
firstly, a hyperspectral image to be processed is acquired, and in practical application, the hyperspectral image is generally acquired by imaging a real scene containing various ground features, wherein a large amount of ground feature detail information is contained. It is known that hyperspectral images are obtained by simultaneously imaging a target region from a plurality of consecutive and subdivided spectral bands, which contain not only the image information of the target region but also the spectral information of the target region.
Step 200, dividing the hyperspectral image into rows according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
step 300, dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing chessboard rows of the hyperspectral image;
step 400, constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
the method comprises the steps of dividing a hyperspectral image based on the spectrum wave bands and the pixel numbers of the hyperspectral image, constructing a checkerboard topological frame corresponding to the hyperspectral image, specifically, dividing rows and columns of the hyperspectral image according to the number of the spectrum wave bands of the hyperspectral image, constructing checkerboard columns, dividing rows of the hyperspectral image according to the pixel numbers of the hyperspectral image, constructing checkerboard rows, and constructing the checkerboard topological frame corresponding to the hyperspectral image based on the constructed checkerboard columns and the checkerboard rows.
Further, when the checkerboard topology frame corresponding to the hyperspectral image is constructed, the rows and columns of the hyperspectral image are divided based on the pixel values of the pixels in the hyperspectral image, the spectral bands of the hyperspectral image and other information, and the rows and columns in the checkerboard topology frame are constructed.
And 500, determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
And determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the constructed checkerboard topology frame, thereby determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected. The to-be-detected pixels can be all or part of pixels in the hyperspectral image, and are not particularly limited herein, and the target anomaly score of each to-be-detected pixel is specifically obtained by carrying out anomaly detection on each to-be-detected pixel based on a constructed chessboard topology frame, and the anomaly score of each to-be-detected pixel is determined by detecting the distribution condition of each to-be-detected pixel in the constructed chessboard topology frame.
In the embodiment, a chessboard row and a chessboard column of the hyperspectral image are constructed by acquiring the hyperspectral image to be processed and dividing the hyperspectral image into rows and columns according to the wave band number and the pixel number of the hyperspectral image, so that a chessboard topology frame of the hyperspectral image is constructed; and determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the constructed checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected. And disassembling the hyperspectral image through a framework chessboard topology frame, detecting the anomalies of the pixels to be detected one by one, fully excavating the characteristics of the hyperspectral image, extracting the ground feature detail information in the hyperspectral image, and improving the accuracy of anomaly detection of the hyperspectral image.
In a preferred embodiment, the constructed checkerboard topology is a ChessBoard (X, column, row), where column and row are the number of columns and rows, respectively, set by the checkerboard topology. In step 200, the hyperspectral image is subjected to column division according to the band data of the hyperspectral image, and a checkerboard column of a checkerboard topology frame is constructed, specifically comprising:
step 201, extracting a target image of the hyperspectral image on each wave band according to the wave band number of the hyperspectral image;
step 202, determining a first pixel value interval of pixels in the target image, performing equally-spaced column division on the target image according to the first pixel value interval, and unifying the number of pixels distributed in each column interval planned to be divided to obtain a base number set of a wave band corresponding to the target image;
step 203, constructing a checkerboard column of the hyperspectral image based on the radix set.
For hyperspectral image X ε R L×N Wherein L is the number of wave bands of the hyperspectral image X, N is the number of pixels of the hyperspectral image X, when the chessboard is constructed, the hyperspectral image on each wave band is taken as a main body, firstly, the target image X of the hyperspectral image on each wave band is extracted according to the number of the wave bands of the hyperspectral image dim ,(X dim =X(i),X dim ∈R 1×N I=1, 2,3, … L) and then in the target image X dim For the main body, determining a pixel value interval of a pixel in the target image, namely, for different pixels in the target image, the pixel values of the pixels in the target image may be the same or different, and determining the maximum value and the minimum value of the pixel in the target image based on the pixel values of the pixels in the target image, thereby obtaining the pixel value interval of the target image, namely, a first pixel value interval. And according to the first pixel value interval, performing equally-spaced column division on the maximum value-minimum value interval according to the set chessboard column number column to obtain a plurality of column intervals under the pixel space corresponding to the target image. Dividing the target image into rows, namely distributing each pixel in the target image into corresponding row intervals according to pixel values thereof, and counting the quantity of the pixels distributed in each row interval planned to be divided to obtain a group of base ChessCol under the wave band corresponding to the target image i ,ChessCol i ∈R 1×column . It is known that the target image corresponding to the hyperspectral image includes a plurality of target images, each target image is subjected to column division to obtain a group of cardinalities corresponding to each spectrum band of the hyperspectral image, and the checkerboard column ChessCol of the hyperspectral image is constructed based on the obtained groups of cardinalities.
Further, in step 300, the hyperspectral image is divided into rows according to the number of pixels of the hyperspectral image, and a checkerboard row of the hyperspectral image is constructed, which specifically includes:
step 301, obtaining a second pixel value interval of a target pixel to be detected in the hyperspectral image; the target to-be-detected pixel is any to-be-detected pixel in the hyperspectral image;
step 301, performing equidistant line division on the hyperspectral image according to the second pixel value interval, and counting the band numbers and band numbers occupied by the target to-be-detected pixels in each divided line interval;
step 302, generating a wave band distribution vector of the target pixel to be detected according to the wave band number;
step 303, based on the chessboard columns, acquiring a base set corresponding to each band number, and calculating the base sum of all base numbers in the base set;
step 304, generating a base distribution vector of the target pixel to be detected according to the base sum;
and 305, constructing a chessboard row of the hyperspectral image based on the wave band distribution vector and the base distribution vector of the target pixel to be detected.
In the construction of the chessboard line of the hyperspectral image, the pixels to be detected in the hyperspectral image are taken as the main body, specifically, a single pixel to be detected in the hyperspectral image is extracted as a target pixel to be detected x j Wherein x is j Is the j-th pixel in hyperspectral image X, and X= [ X ] 1 ,x 2 ,…x N ]. With the target to-be-detected pixel x j The method comprises the steps of taking a hyperspectral image as a main body, obtaining the maximum value and the minimum value of the pixel value of the hyperspectral image according to the pixel value of each pixel in the hyperspectral image, obtaining a second pixel value interval, and carrying out equally-spaced row division on the hyperspectral image according to the second pixel value interval, namely distributing the pixels in the hyperspectral image into corresponding row intervals according to the pixel values of the pixels.
It can be understood that the same row interval corresponds to a plurality of spectrum bands of the hyperspectral image, that is, in the same row interval, the same pixel may occupy one or a plurality of spectrum bands, the distribution condition of the target pixel to be detected in each row interval in the hyperspectral image is counted, and the band distribution vector and the base distribution vector corresponding to the target pixel to be detected are generated. Specifically, the band number and the band number occupied by the pixel to be measured in each divided line interval are counted, and the band number is recorded in a variable BandSet k In (k is a positive integer for representing a sequence number), and the band number is recorded in the variable BandSum k In the method, the corresponding wave band distribution direction of each row interval is generated according to the wave band number of the target to-be-detected pixel Quantity BDV j . According to the variable BandSet k The wave band number recorded in the image sensor is used for obtaining a target pixel x to be detected j A corresponding set of cardinalities and recorded in the variable CardSet k In which the radix sum of the group of radix is recorded in the variable CardSum k In the method, a base distribution vector CDV corresponding to each row interval is generated according to the base corresponding to the target to-be-detected pixel and the base corresponding to the target to-be-detected pixel j . And adding the wave band distribution vector and the base distribution vector of the pixel to be detected into the divided row interval, and obtaining the wave band distribution vector and the base distribution vector of each pixel to be detected according to the mode, thereby constructing a chessboard row ChessRow of the hyperspectral image.
And integrating the constructed chessboard rows and the chessboard columns to obtain a chessboard topology frame corresponding to the hyperspectral image, wherein the chessboard rows and the chessboard columns are integrated, and specifically, according to the distribution condition of each pixel in the hyperspectral image in the chessboard rows and the chessboard columns, the chessboard patterns where each pixel is positioned in the pixel space constructed by the chessboard topology frame and the number of pixels distributed in each chessboard pattern, namely, the cardinality corresponding to each chessboard pattern are determined. Based on the constructed chessboard topology frame, the abnormal score of each pixel to be detected in the hyperspectral image can be detected, so that the abnormal detection result of the hyperspectral image is determined. In step 500, determining a target anomaly score of each pixel to be detected in the hyperspectral image based on the constructed checkerboard topology frame, specifically including:
Step 501, determining a target chessboard row corresponding to each target pixel in the hyperspectral image based on the chessboard topology frame; the target pixel is any pixel to be detected in the hyperspectral image;
step 502, determining a target wave band distribution vector and a target base distribution vector corresponding to the target pixel according to the target chessboard row;
step 503, determining a first anomaly score of the target pixel according to the target band distribution vector and the target base distribution vector;
and step 504, obtaining a mean vector of the hyperspectral image, and weighting the first anomaly score based on the mean vector to obtain a target anomaly score of the target pixel.
When the hyperspectral image is subjected to anomaly detection, each pixel to be detected needs to be detected one by one, the anomaly condition of each pixel is determined, and then the anomaly condition of the hyperspectral image is determined. In particular, for a target pixel x in a high-tube spectrum image i Based on the constructed chessboard topology frame, the target pixel x is detected by means of cyclic traversal and the like i Distribution in each checkerboard line to determine the target pixel x i Corresponding target chessboard row ChessRow i Wherein, the target pixel x i Is any pixel to be detected in the hyperspectral image X. Through the target pixel x i Corresponding chessboard row chessRow i Determining its band distribution vector BDV i Sum radix distribution vector CDV i (BDV i ,CDV i ∈R row×1 ). According to the target pixel x i Is a band distribution vector BDV of (2) i Sum radix distribution vector CDV i . According to the target pixel x i Is a band distribution vector BDV of (2) i Sum radix distribution vector CDV i Determining a target pixel x i Acquiring a mean vector mu of the hyperspectral image, and aiming at a target pixel x based on the mean vector mu i Weighting the first anomaly score to obtain a target pixel x i Target anomaly score of (2).
Wherein, the target pixel x i Is a band distribution vector BDV of (2) i Characterizing a target pixel x i Can reflect the target pixel x i Trend of change in spectral space; target pixel x i Radix distribution vector CDV i Characterizing a target pixel x i Can reflect the image information of the target pixel x i Similarity to other pixels in pixel space, reflecting the target pixel x i Differences in pixel space; the mean vector μ of the hyperspectral image characterizes the overall characteristics of the hyperspectral image; according to the target pixel x i Is used for determining the target pixel x i Based on the first anomaly score of the hyperspectral imageLine weighting processing can accurately obtain a target pixel x i Target anomaly score of (2).
Further, in step 503, determining a first anomaly score of the target pixel according to the band distribution vector and the base distribution vector of the target pixel, further includes:
step 5031, determining a target band number and a target base set occupied by the target pixel in the target chessboard row according to the target band distribution vector and the target base distribution vector;
step 5032, using the band number corresponding to the minimum value in the target radix set as the best sub-band corresponding to the target pixel in the target band number;
step 5033, determining a target chessboard column corresponding to the optimal sub-band in the target chessboard row and a target base corresponding to the target pixel in the target chessboard column;
step 5034, obtaining a maximum radix in the target chessboard route, and calculating a ratio of the target radix to the maximum radix;
step 5035, determining a first anomaly score for the target pixel according to the ratio.
In determining the target pixel x i By its band distribution vector BDV at the first anomaly score of (2) i Recording target pixel x i On the target chessboard row ChessRow i A target band number occupied in the system, and a group of cardinalities corresponding to the target band number, namely a target cardinality set CardSet j . The target band number includes one or more, in which the target radix set CardSet j The minimum value of (a) corresponds to the band number MinCardIndex j For the target pixel x i On the target chessboard row ChessRow i Is defined in the above-mentioned patent document. Determining a target chess board column ChessCol corresponding to the optimal sub-band j Acquiring a target pixel x in a target chessboard array corresponding to the optimal sub-band i Target base ChessCol of the checkerboard ij And target chess board column ChessCol j Maximum radix MaxChessCol in (C) j =max(ChessCol j ) According to the target radix ChessCol ij With the maximum radix MaxChessCol j Ratio of CardRatio j Determining a target pixel x i Is a first anomaly score of (a). Wherein, the target pixel x i Is the first anomaly score of AnomalyScore i For the target base ChessCol ij With the maximum radix MaxChessCol j The accumulation of the ratio of (2) on the current board line, i.e. AnomalyScare i =AnomalyScore i +CardRatio j
Further, in step 504, the weighting process is performed on the first anomaly score based on the mean vector of the hyperspectral image, and the method further includes:
Step 5041, obtaining a band distribution vector and a base distribution vector of the mean vector on the checkerboard topological frame;
step 5042, calculating a first difference vector between the band distribution vector of the mean vector and the target band distribution vector of the target pixel, and a second difference vector between the radix distribution vector of the mean vector and the target radix distribution vector of the target pixel;
step 5043, determining a weight value according to the first difference vector and the second difference vector, and weighting the first anomaly score based on the weight value.
When the first anomaly score is weighted based on the mean vector of the hyperspectral image, firstly, a band distribution vector BDV of the mean vector mu on the checkerboard topological frame is obtained μ Sum radix distribution vector CDV μ (BDV μ ,CDV μ ∈R row×1 ) Then calculate the mean value vector mu and the target pixel x i Is the band distribution vector difference BDV of (2) sub Sum radix distribution vector difference CDV sub Wherein, the mean value vector mu and the target pixel x are calculated i The difference value of the band distribution vectors of (a) is a first difference value vector, and the average value vector mu and the target pixel x are calculated i The radix distribution vector difference of (2) is the second difference vector, namely BDV sub =BDV i -BDV μ ,CDV sub =CDV i -CDV μ . According to the first difference vector sumA second difference vector, a weight value is determined, and the first anomaly score is weighted based on the weight value to obtain a target pixel x i Target anomaly score of (2). The weight value may be 1 norm of two difference vectors, and the 1 norms of the first difference vector and the second difference vector are respectively taken to obtain the corresponding weight value: w (w) 1 =‖BDV sub1 ,w 2 =‖CDV sub1 Based on the weight value w 1 And w 2 For the first anomaly score AnomalyScare i Weighting to obtain target anomaly score TargetScore i =AnomalyScore i ×w 1 ×w 2
Preferably, in step 500, determining an anomaly detection result for the hyperspectral image according to the target anomaly score of each pixel to be detected may further include:
step 510, determining abnormal pixels in the hyperspectral image according to the target abnormal score of each pixel to be detected;
and step 520, determining an abnormal detection result of the hyperspectral image according to the abnormal pixel.
According to the target anomaly score of each pixel to be detected, determining an anomaly pixel in the hyperspectral image, and according to the anomaly pixel, determining an anomaly detection result of the hyperspectral image. When determining the abnormal pixels, an abnormal score threshold is set according to experience, or the abnormal score threshold is adaptively determined according to the target abnormal scores of the pixels to be detected, for example, an average value of the target abnormal scores of the pixels to be detected is used as the abnormal score threshold, the abnormal pixels with the target abnormal scores exceeding the abnormal score threshold in the hyperspectral image are identified, whether the hyperspectral image contains abnormal contents or not can be determined according to the ground object information corresponding to the abnormal pixels, and therefore an abnormal detection result of the hyperspectral image is obtained.
In this embodiment, based on the pixel interval of the hyperspectral image, the image under the single spectrum band and the single pixel in the hyperspectral image are respectively taken as main bodies, the hyperspectral image is subjected to row-column division, a checkerboard topology frame is constructed, the pixels of the hyperspectral image are divided based on the pixel topology space of the checkerboard topology frame, and the image features and the spectrum features of the hyperspectral image can be fully mined and extracted, so that the accuracy of anomaly detection of the hyperspectral image is improved.
Further, the difference in spectrum trend and morphology between the anomaly and the background in the hyperspectral image is highlighted through the band distribution vector and the base distribution vector, the optimal sub-band is distributed for each pixel to be detected in a self-adaptive mode during anomaly detection, and the deviation degree of relatively high-quality and high-density groups of the pixel to be detected on the bands is quantized to obtain anomaly scores. And the anomaly score is weighted through a difference vector between the pixel to be detected and the mean vector of the hyperspectral image, so that the anomaly is accurately separated from the background, and the high-precision anomaly detection requirements under different imaging scenes can be met.
The hyperspectral image anomaly detection device provided by the invention is described below, and the hyperspectral image anomaly detection device described below and the hyperspectral image anomaly detection method described above can be referred to correspondingly.
Referring to fig. 2, a hyperspectral image anomaly detection apparatus provided by an embodiment of the present invention includes:
an image acquisition module 10 for acquiring a hyperspectral image to be processed;
the chessboard route construction module 20 is used for dividing the hyperspectral image into routes according to the wave band number of the hyperspectral image, and constructing chessboard route of the hyperspectral image;
the chessboard route construction module 30 is configured to divide the hyperspectral image into routes according to the number of pixels of the hyperspectral image, and construct chessboard routes of the hyperspectral image;
a checkerboard frame construction module 40 for constructing a checkerboard topology of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
the anomaly detection module 50 is configured to determine a target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determine an anomaly detection result for the hyperspectral image according to the target anomaly score of each pixel to be detected.
In one embodiment, the anomaly detection module 50 is further configured to:
determining a target chessboard row corresponding to each target pixel in the hyperspectral image based on the chessboard topology frame; the target pixel is any pixel to be detected in the hyperspectral image;
Determining a target wave band distribution vector and a target base distribution vector corresponding to the target pixel according to the target chessboard;
determining a first anomaly score of the target pixel according to the target band distribution vector and the target base distribution vector;
and acquiring a mean vector of the hyperspectral image, and weighting the first anomaly score based on the mean vector to obtain a target anomaly score of the target pixel.
In one embodiment, the anomaly detection module 50 is further configured to:
determining a target band number and a target base set occupied by the target pixel in the target chessboard row according to the target band distribution vector and the target base distribution vector;
taking the band number corresponding to the minimum value in the target base number set as the optimal sub-band corresponding to the target pixel;
determining a target chessboard column corresponding to the optimal sub-band in the target chessboard row and a target base corresponding to the target pixel in the target chessboard column;
obtaining a maximum base number in the target chessboard route, and calculating the ratio of the target base number to the maximum base number;
And determining a first anomaly score of the target pixel according to the ratio.
In one embodiment, the anomaly detection module 50 is further configured to:
acquiring a wave band distribution vector and a base distribution vector of the mean vector on the checkerboard topology frame;
calculating a first difference vector between the band distribution vector of the mean vector and the target band distribution vector of the target pixel, and a second difference vector between the base distribution vector of the mean vector and the target base distribution vector of the target pixel;
and determining a weight value according to the first difference value vector and the second difference value vector, and carrying out weighting processing on the first anomaly score based on the weight value.
In one embodiment, the checkerboard construction module 20 is further configured to:
extracting a target image of the hyperspectral image on each wave band according to the wave band number of the hyperspectral image;
determining a first pixel value interval of pixels in the target image, performing equally-spaced column division on the target image according to the first pixel value interval, and unifying the quantity of pixels distributed in each column interval planned to be divided to obtain a base number set of a wave band corresponding to the target image;
And constructing a checkerboard column of the hyperspectral image based on the radix set.
In one embodiment, the checkerboard line construction module 30 is further configured to:
acquiring a second pixel value interval of a target pixel to be detected in the hyperspectral image; the target to-be-detected pixel is any to-be-detected pixel in the hyperspectral image;
performing equidistant line division on the hyperspectral image according to the second pixel value interval, and counting the band numbers and band numbers occupied by the target to-be-detected pixels in each divided line interval;
generating a wave band distribution vector of the target pixel to be detected according to the wave band number;
based on the chessboard columns, acquiring a base set corresponding to each band number, and calculating the base sum of all base numbers in the base set;
generating a base distribution vector of the target pixel to be detected according to the base sum;
and constructing a chessboard row of the hyperspectral image based on the wave band distribution vector and the base distribution vector of the target pixel to be detected.
In one embodiment, the anomaly detection module 50 is further configured to:
determining abnormal pixels in the hyperspectral image according to the target abnormal score of each pixel to be detected;
And determining an abnormal detection result of the hyperspectral image according to the abnormal pixel.
Fig. 3 illustrates a physical schematic diagram of an electronic device, as shown in fig. 3, where the electronic device may include: processor 310, communication interface (Communications Interface) 320, memory 330 and communication bus 340, wherein processor 310, communication interface 320, memory 330 accomplish communication with each other through communication bus 340. The processor 310 may invoke logic instructions in the memory 330 to perform a hyperspectral image anomaly detection method comprising:
acquiring a hyperspectral image to be processed;
dividing the hyperspectral image into rows and columns according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing a chessboard row of the hyperspectral image;
constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
Further, the logic instructions in the memory 330 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product, the computer program product including a computer program, the computer program being storable on a non-transitory computer readable storage medium, the computer program, when executed by a processor, being capable of executing the hyperspectral image anomaly detection method provided by the above methods, the method comprising:
Acquiring a hyperspectral image to be processed;
dividing the hyperspectral image into rows and columns according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing a chessboard row of the hyperspectral image;
constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the hyperspectral image anomaly detection method provided by the above methods, the method comprising:
acquiring a hyperspectral image to be processed;
dividing the hyperspectral image into rows and columns according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing a chessboard row of the hyperspectral image;
Constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A hyperspectral image anomaly detection method, characterized by comprising:
acquiring a hyperspectral image to be processed;
dividing the hyperspectral image into rows and columns according to the wave band number of the hyperspectral image, and constructing chessboard routes of the hyperspectral image;
dividing the hyperspectral image into rows according to the pixel number of the hyperspectral image, and constructing a chessboard row of the hyperspectral image;
constructing a checkerboard topology frame of the hyperspectral image based on the checkerboard columns and the checkerboard rows;
determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the checkerboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
2. The hyperspectral image anomaly detection method of claim 1, wherein the determining the target anomaly score of each pixel under test in the hyperspectral image based on the checkerboard topology frame comprises:
determining a target chessboard row corresponding to each target pixel in the hyperspectral image based on the chessboard topology frame; the target pixel is any pixel to be detected in the hyperspectral image;
determining a target wave band distribution vector and a target base distribution vector corresponding to the target pixel according to the target chessboard;
determining a first anomaly score of the target pixel according to the target band distribution vector and the target base distribution vector;
and acquiring a mean vector of the hyperspectral image, and weighting the first anomaly score based on the mean vector to obtain a target anomaly score of the target pixel.
3. The hyperspectral image anomaly detection method of claim 2, wherein the determining the first anomaly score for the target pixel from the target band distribution vector and the target cardinal distribution vector comprises:
determining a target band number and a target base set occupied by the target pixel in the target chessboard row according to the target band distribution vector and the target base distribution vector;
Taking the band number corresponding to the minimum value in the target base number set as the optimal sub-band corresponding to the target pixel;
determining a target chessboard column corresponding to the optimal sub-band in the target chessboard row and a target base corresponding to the target pixel in the target chessboard column;
obtaining a maximum base number in the target chessboard route, and calculating the ratio of the target base number to the maximum base number;
and determining a first anomaly score of the target pixel according to the ratio.
4. The hyperspectral image anomaly detection method of claim 2, wherein the weighting the first anomaly score based on the mean vector comprises:
acquiring a wave band distribution vector and a base distribution vector of the mean vector on the checkerboard topology frame;
calculating a first difference vector between the band distribution vector of the mean vector and the target band distribution vector of the target pixel, and a second difference vector between the base distribution vector of the mean vector and the target base distribution vector of the target pixel;
and determining a weight value according to the first difference value vector and the second difference value vector, and carrying out weighting processing on the first anomaly score based on the weight value.
5. The hyperspectral image anomaly detection method according to claim 1, wherein the step of dividing the hyperspectral image into columns and rows according to the number of bands of the hyperspectral image, constructing a checkerboard column of the hyperspectral image, comprises:
extracting a target image of the hyperspectral image on each wave band according to the wave band number of the hyperspectral image;
determining a first pixel value interval of pixels in the target image, performing equally-spaced column division on the target image according to the first pixel value interval, and unifying the quantity of pixels distributed in each column interval planned to be divided to obtain a base number set of a wave band corresponding to the target image;
and constructing a checkerboard column of the hyperspectral image based on the radix set.
6. The hyperspectral image anomaly detection method of claim 5, wherein the dividing the hyperspectral image into lines according to the number of pixels of the hyperspectral image, constructing the checkerboard lines of the hyperspectral image, comprises:
acquiring a second pixel value interval of a target pixel to be detected in the hyperspectral image; the target to-be-detected pixel is any to-be-detected pixel in the hyperspectral image;
Performing equidistant line division on the hyperspectral image according to the second pixel value interval, and counting the band numbers and band numbers occupied by the target to-be-detected pixels in each divided line interval;
generating a wave band distribution vector of the target pixel to be detected according to the wave band number;
based on the chessboard columns, acquiring a base set corresponding to each band number, and calculating the base sum of all base numbers in the base set;
generating a base distribution vector of the target pixel to be detected according to the base sum;
and constructing a chessboard row of the hyperspectral image based on the wave band distribution vector and the base distribution vector of the target pixel to be detected.
7. The hyperspectral image anomaly detection method of claim 1, wherein the determining the anomaly detection result for the hyperspectral image according to the target anomaly score of each pixel under test comprises:
determining abnormal pixels in the hyperspectral image according to the target abnormal score of each pixel to be detected;
and determining an abnormal detection result of the hyperspectral image according to the abnormal pixel.
8. A hyperspectral image anomaly detection device, characterized by comprising:
The image acquisition module is used for acquiring a hyperspectral image to be processed;
the chessboard column construction module is used for dividing the hyperspectral image into columns and rows according to the wave band number of the hyperspectral image, and constructing chessboard columns of the hyperspectral image;
the chessboard line construction module is used for dividing the hyperspectral image into lines according to the pixel number of the hyperspectral image, and constructing the chessboard line of the hyperspectral image;
the chessboard frame construction module is used for constructing a chessboard topology frame of the hyperspectral image based on the chessboard columns and the chessboard rows;
the anomaly detection module is used for determining the target anomaly score of each pixel to be detected in the hyperspectral image based on the chessboard topology frame, and determining the anomaly detection result of the hyperspectral image according to the target anomaly score of each pixel to be detected.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the hyperspectral image anomaly detection method of any one of claims 1 to 7 when the program is executed by the processor.
10. A non-transitory computer-readable storage medium having stored thereon a computer program, wherein the computer program when executed by a processor implements the hyperspectral image anomaly detection method of any one of claims 1 to 7.
CN202310077517.XA 2023-01-17 2023-01-17 Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium Pending CN116205858A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310077517.XA CN116205858A (en) 2023-01-17 2023-01-17 Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310077517.XA CN116205858A (en) 2023-01-17 2023-01-17 Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium

Publications (1)

Publication Number Publication Date
CN116205858A true CN116205858A (en) 2023-06-02

Family

ID=86508934

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310077517.XA Pending CN116205858A (en) 2023-01-17 2023-01-17 Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium

Country Status (1)

Country Link
CN (1) CN116205858A (en)

Similar Documents

Publication Publication Date Title
CN111199214B (en) Residual network multispectral image ground object classification method
CN113238227B (en) Improved least square phase unwrapping method and system combined with deep learning
CN109886937B (en) Insulator defect detection method based on super-pixel segmentation image recognition
CN110992366B (en) Image semantic segmentation method, device and storage medium
CN111476835B (en) Unsupervised depth prediction method, system and device for consistency of multi-view images
CN113569756B (en) Abnormal behavior detection and positioning method, system, terminal equipment and readable storage medium
CN106909539A (en) Image indexing system, server, database and related methods
CN111160478B (en) Hyperspectral target significance detection method based on deep learning
CN113838064A (en) Cloud removing method using multi-temporal remote sensing data based on branch GAN
CN116091930A (en) Terrace drawing method, device, equipment and storage medium based on remote sensing
CN113191962A (en) Underwater image color recovery method and device based on environment background light and storage medium
CN116205858A (en) Hyperspectral image anomaly detection method, hyperspectral image anomaly detection device, hyperspectral image anomaly detection equipment and hyperspectral image anomaly detection storage medium
CN107943903A (en) Video retrieval method and device, computer equipment, storage medium
JP4516940B2 (en) Iris recognition method using cumulative sum-based change point analysis and apparatus thereof
CN112489103A (en) High-resolution depth map acquisition method and system
CN109961405B (en) Image filtering method and device
CN107067397A (en) A kind of image grading method based on infrared image complexity
CN115909077A (en) Hyperspectral image change detection method based on unsupervised spectrum unmixing neural network
CN110349166A (en) A kind of blood vessel segmentation method, device and equipment being directed to retinal images
JP4178533B2 (en) Tree crown extraction system
CN112419407B (en) Cloud cluster displacement vector calculation method and device based on cloud cluster edge recognition
CN115760908A (en) Insulator tracking method and device based on capsule network perception characteristics
CN102551683B (en) Three-dimensional temperature imaging method and system
CN113554685A (en) Method and device for detecting moving target of remote sensing satellite, electronic equipment and storage medium
CN113379922A (en) Foreground extraction method, device, storage medium and equipment

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