Ship recognition method and system based on high-resolution infrared simulation images
By performing edge detection and super-resolution reconstruction on marine infrared images, the confidence in sea surface temperature difference and sea surface confidence are calculated, and pixel points are divided, the problem of inaccurate ship recognition in infrared images is solved, and ship recognition of high-resolution infrared simulation images is achieved.
Patent Information
- Application Number
- CN202411773745.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-05
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2044-12-05
AI Technical Summary
The ship recognition method based on deep learning in infrared images due to blurring edge features, resulting in unclear features of the simulation image, affecting the accuracy of the recognition.
The high-resolution infrared simulation image method is used to detect edges and super-resolution reconstruction of marine infrared images, and reconstruct the marine infrared images, calculate the sea surface temperature difference confidence and sea surface confidence of pixel points, divide the pixel points to be divided and the pixel points of suspicious ships, and finally identify the ship through high-resolution images.
It improves the accuracy of ship recognition in infrared images, solves the problem of unclear features caused by blurred edge features, and enhances the ability to identify ship locations.
Smart Images

Figure CN119229303B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a ship recognition method and system based on high-resolution infrared simulation images, belonging to the technical field of image processing. Background Art
[0002] Ship identification on the sea surface can help maritime administration agencies quickly locate ships in distress, and can also help maritime administration agencies more effectively supervise maritime traffic, prevent and respond to maritime accidents, and ensure navigation safety. Infrared detection technology relies on the temperature difference between objects and the environment for thermal imaging. It also has certain imaging capabilities under environmental conditions such as low light or no light, and is widely used for ship identification on the sea surface. In order to better supervise maritime traffic, it is necessary to accurately identify ships in infrared images of different sea surface areas, and reasonably arrange and confirm the location of ships. Deep learning methods are generally used to identify the location of ships in images.
[0003] However, the accuracy of target detection based on deep learning methods is greatly affected by the training data set. The blurred edge features of infrared images themselves easily lead to unclear features of generated infrared images, which is not conducive to the training of deep learning models and affects the accuracy of ship recognition in infrared images. Summary of the invention
[0004] The present invention provides a ship recognition method and system based on high-resolution infrared simulation images to solve the problem that the edge features of infrared images are blurred, resulting in unclear features of simulation images and inaccurate ship recognition. The technical solutions adopted are as follows:
[0005] The present invention provides a ship recognition method based on high-resolution infrared simulation images, the method comprising the following steps:
[0006] Collect multiple marine infrared images for ship identification and analyze each marine infrared image separately;
[0007] Detect the edge of the marine infrared image to obtain strong edge pixels and weak edge pixels, perform super-resolution reconstruction on the marine infrared image to obtain the reconstructed marine infrared image, record any pixel in the reconstructed marine infrared image as a target pixel, obtain the sea surface temperature difference confidence of the target pixel according to the gray value distribution and position distribution of the pixel in the vicinity of the corresponding position pixel in the marine infrared image, and the position distribution of the strong edge pixel, and divide the pixel to be divided and the pixel of the suspicious ship according to the sea surface temperature difference confidence of the pixel in the reconstructed marine infrared image;
[0008] According to the position distribution of all weak edge pixels and strong edge pixels in the vicinity of the pixel at the corresponding position of the target pixel in the marine infrared image, the sea surface confidence of the target pixel is determined, and the pixel to be divided is divided into sea surface pixels and ship pixels according to the sea surface confidence of all pixels in the marine infrared image;
[0009] The reconstructed marine infrared image is super-resolution reconstructed to obtain a high-resolution marine infrared image corresponding to the marine infrared image, and the ship is identified based on all high-resolution marine infrared images.
[0010] Further, the sea surface temperature difference confidence of the target pixel is obtained according to the gray value distribution and position distribution of the pixel points in the reconstructed marine infrared image, as well as the position distribution of the strong edge pixel points, including the specific method of:
[0011] According to the coordinates of the target pixel points in the reconstructed marine infrared image, the target pixel points are mapped to the marine infrared image to obtain the original target pixel points;
[0012] According to the grayscale values of the neighboring pixels of the original target pixel, the number of strong edge pixels among the neighboring pixels of the original target pixel, and the position distribution of the original target pixel and its neighboring pixels, the confidence of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image is obtained.
[0013] Furthermore, the sea surface temperature difference confidence of the target pixel point is obtained by:
[0014] The pixel points with the closest Euclidean distance to the original target pixel point in the marine infrared image are recorded as the neighboring pixel points of the original target pixel point;
[0015] The maximum value of the grayscale value of all neighboring pixels of the original target pixel, the number of strong edge pixels among all neighboring pixels of the original target pixel, the average value of the distance between the original target pixel and all neighboring pixels, and a preset first constant are added together as the first cumulative sum of the original target pixel; the reciprocal of the first cumulative sum of the original target pixel is added together as the confidence level of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image.
[0016] Furthermore, the specific method of dividing the pixels to be divided and the suspicious ship pixels is:
[0017] The sea surface temperature difference confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the first division threshold;
[0018] The pixel points whose sea surface temperature difference confidence in the reconstructed marine infrared image is greater than the first division threshold are recorded as pixels to be divided, and the pixel points whose sea surface temperature difference confidence in the reconstructed marine infrared image is less than or equal to the first division threshold are recorded as suspicious ship pixels.
[0019] Furthermore, the sea surface confidence of the target pixel point is obtained by:
[0020] The original target pixel is taken as the central pixel, a local window with a side length equal to a first preset threshold is established, and the cumulative sum of the Euclidean distances between all the strong edge pixels in the local window of the original target pixel and the original target pixel is recorded as the second cumulative sum of the original target pixel;
[0021] The number of weak edge pixels in the neighboring pixels of the original target pixel, the average of the local density of the weak edge pixels, the number of strong edge pixels contained in the local window of the original target pixel, and a preset first constant are accumulated and recorded as the third accumulated sum of the original target pixel;
[0022] The ratio of the second cumulative sum to the third cumulative sum of the original target pixel point is recorded as the sea surface confidence of the target pixel point corresponding to the original target pixel point in the reconstructed marine infrared image.
[0023] Furthermore, the pixel points to be divided into sea surface pixel points and ship pixel points according to the sea surface confidence of all pixel points in the marine infrared image include the following specific methods:
[0024] The sea surface confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the second division threshold;
[0025] The pixel points whose sea surface confidence in the reconstructed marine infrared image is greater than the second division threshold are recorded as sea surface pixels, and the pixel points whose sea surface confidence in the reconstructed marine infrared image is less than or equal to the second division threshold are recorded as ship pixels.
[0026] Furthermore, the super-resolution reconstruction of the reconstructed marine infrared image to obtain a high-resolution marine infrared image corresponding to the marine infrared image includes the following specific methods:
[0027] The coordinate positions of the sea surface pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bilinear interpolation method to obtain the interpolation pixel value of each sea surface pixel in the reconstructed marine infrared image; the coordinate positions of the suspicious ship pixels and the ship pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bicubic interpolation method to obtain the interpolation pixel value of each suspicious ship pixel and each ship pixel in the reconstructed marine infrared image;
[0028] The interpolated pixel values of all pixels in the reconstructed marine infrared image are adjusted to obtain the adjusted pixel values of all pixels, and the adjusted pixel values of all pixels in the reconstructed marine infrared image are used as the pixel values of the pixels to obtain a high-resolution marine infrared image.
[0029] Furthermore, the interpolation pixel values of all pixels in the reconstructed marine infrared image are adjusted to obtain the adjusted pixel values of all pixels, including the following specific methods:
[0030] The interpolated pixel values of all pixels in the reconstructed marine infrared image are rounded, and the rounded values greater than 255 are assigned to 255, and the rounded values less than 0 are assigned to 0, so as to obtain the adjusted pixel values of all pixels in the reconstructed marine infrared image.
[0031] Furthermore, the specific method of identifying ships based on all high-resolution marine infrared images includes:
[0032] The data set consisting of all high-resolution infrared images is used as a high-quality training set for the ship recognition model, and the SSD target detection network is trained to obtain the ship recognition model;
[0033] The high-resolution marine infrared image corresponding to the marine infrared image that needs to be used for ship identification is input into the trained ship identification model to obtain the category information and position information of each pixel in the high-resolution marine infrared image, and obtain the recognition result of the ship in the high-resolution marine infrared image.
[0034] The present invention also provides a ship identification system based on high-resolution infrared simulation images, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements the steps of any one of the above methods when executing the computer program.
[0035] The beneficial effects of the present invention are:
[0036] The present application divides the positions with relatively high temperature in the marine infrared image, namely, strong edge pixels and weak edge pixels, and then, based on the characteristic that the temperature difference on the sea surface will cause the relatively high temperature of some sea water positions, the characteristic of relatively high temperature in the local range of the target pixel in the reconstructed marine infrared image obtained by super-resolution reconstruction of the marine infrared image is analyzed, the sea surface temperature difference confidence of the target pixel is obtained, and the pixel to be divided and the pixel of the suspicious ship are divided, the pixel to be divided corresponds to the position with uneven temperature on the sea surface or the ship, and the pixel of the suspicious ship corresponds to the ship on the sea surface; further, the pixel to be divided is continued to be divided, and the pixel corresponding to the position with uneven temperature on the sea surface and the position of the ship are divided, and the confidence of the sea surface temperature difference on the target pixel is obtained. There are temperature differences in the seawater at the same position. The temperature difference at the junction of different temperatures is small, resulting in the presence of relatively sparse weak edge pixels near the pixels to be divided at the position of uneven temperature on the sea surface, and the presence of more dense weak edge pixels and strong edge pixels near the pixels to be divided at the position of the ship. The sea surface confidence of the target pixel is determined and the pixels to be divided are divided into sea surface pixels and ship pixels. Finally, super-resolution reconstruction is performed on the reconstructed marine infrared image to obtain a high-resolution marine infrared image corresponding to the marine infrared image. Ships are identified based on all high-resolution marine infrared images to solve the problem that the blurred edge features of the infrared image lead to unclear features of the simulation image and inaccurate ship identification. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0038] Figure 1 A schematic diagram of a process flow of a ship recognition method based on high-resolution infrared simulation images provided by an embodiment of the present invention;
[0039] Figure 2 A flowchart of dividing pixels to be divided and pixels of suspicious ships provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0040] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0041] See also Figure 1 , which shows a flow chart of a ship identification method based on high-resolution infrared simulation images provided by an embodiment of the present invention, the method comprising the following steps:
[0042] Step S001, collecting multiple marine infrared images for ship identification.
[0043] Use a marine drone equipped with an infrared thermal imager to collect marine infrared images while the marine drone is flying over the sea. The marine infrared images are grayscale images.
[0044] The target in the marine infrared image is a ship. In this embodiment, 1000 marine infrared images are collected, and the resolution of the marine infrared images is 640×480. In actual application, as other implementation methods, the implementer can decide the number of marine infrared images collected and the resolution of marine infrared images according to actual conditions, and this application does not impose any special restrictions.
[0045] It should be noted that, in order to facilitate image analysis, the median filtering algorithm is used to denoise the marine infrared image to remove the noise in the image. The median filtering denoising is a well-known technology and will not be described in detail. In actual application, the implementer can use other methods of the existing technology such as Gaussian filtering for denoising, which is not limited here.
[0046] At this point, the marine infrared image for ship identification is obtained.
[0047] Step S002, detect the edge of the marine infrared image, obtain strong edge pixels and weak edge pixels, perform super-resolution reconstruction on the marine infrared image, obtain the reconstructed marine infrared image, record any pixel in the reconstructed marine infrared image as a target pixel, and obtain the sea surface temperature difference confidence of the target pixel according to the gray value distribution and position distribution of the pixel in the vicinity of the corresponding position pixel in the marine infrared image, as well as the position distribution of the strong edge pixel, and divide the pixels to be divided and the suspicious ship pixels according to the sea surface temperature difference confidence of the pixel in the reconstructed marine infrared image.
[0048] Infrared thermal imagers take thermal images based on temperature. When the temperature of an object is higher, the grayscale value of the corresponding position of the object in the infrared image is larger. Since the surface temperature of the ship is relatively low, the grayscale value of the edge pixel points of the corresponding area of the ship in the infrared image is not significantly different from the grayscale value of the corresponding pixel points of the seawater. When the SSD (Single Shot MultiBox Detector) target detection network is directly used to determine the ship based on the collected marine infrared image, the ship will also present a relatively fuzzy feature. In order to obtain a high-resolution infrared simulation image, a super-resolution reconstruction algorithm can be used to process the collected infrared image to obtain a high-resolution infrared image. Then, a training data set of the SSD target detection network is established based on the high-resolution infrared image and the SSD target detection network is trained to identify ships in the high-resolution infrared simulation image.
[0049] In the process of acquiring high-resolution infrared images, the infrared images contain ships. The temperature of the fuel engine and the engine room on the ship is high, and the grayscale value of the corresponding area in the infrared image is large. However, the temperature of the seawater at different locations is affected by different factors such as light and ocean currents, and there will be temperature differences. The temperature difference of the sea surface will affect the recognition of the ship. In order to reduce such interference, it is necessary to ensure the accuracy and clarity of the edge information of the ship in the infrared image during the super-resolution reconstruction of the acquired infrared image. Most of the pixels in the marine infrared image correspond to the sea surface, and only a small number of pixels correspond to the ship. In order to make the edge of the ship clearer, the focus is placed on the ship during super-resolution reconstruction.
[0050] At the same time, the seawater in the ocean is always in motion and is heated unevenly. Therefore, there are temperature differences between the seawater at different locations in the ocean. The temperature differences between the seawater will also form areas with higher temperatures in the infrared image, which will interfere with the determination of the target area of the ship. Therefore, it is necessary to eliminate the influence of the edges corresponding to the temperature differences at different locations in the ocean.
[0051] The Canny edge detection algorithm is used to detect the edge of the marine infrared image to obtain the strong edge and weak edge in the marine infrared image. The pixels contained in the strong edge of the marine infrared image are recorded as strong edge pixels, and the pixels contained in the weak edge of the marine infrared image are recorded as weak edge pixels.
[0052] Among them, using the Canny edge detection algorithm to perform edge detection on an image is a well-known technology, and the strong edge and weak edge in the image are well-known definitions in the Canny edge detection algorithm, which will not be repeated here.
[0053] The temperature of the fuel engine and engine room on the ship is higher and more obvious than that of the seawater, so the pixels corresponding to the edges of the fuel engine and engine room on the ship in the marine infrared image are strong edge pixels. The pixels corresponding to the edges of other areas of the ship in the marine infrared image may be weak edge pixels or strong edge pixels.
[0054] The SwinIBSR algorithm is used to perform super-resolution reconstruction on the marine infrared image to obtain a reconstructed marine infrared image. The resolution of the reconstructed marine infrared image obtained in this embodiment is m×n, where m is 1280 and n is 1024.
[0055] Any pixel point in the reconstructed marine infrared image is recorded as a target pixel point. This embodiment is described by taking any pixel point in the reconstructed marine infrared image as an example.
[0056] According to the coordinates of the target pixel in the reconstructed marine infrared image, the target pixel is mapped to the marine infrared image to obtain the original target pixel. If the coordinates of the target pixel in the reconstructed marine infrared image are , then the coordinates of the original target pixel in the marine infrared image are .
[0057] In the marine infrared image, P pixels with the closest Euclidean distance to the original target pixel are selected, and these P pixels are recorded as neighboring pixels of the original target pixel. Wherein, P is the second preset threshold value, and the value of the second preset threshold value in this embodiment is 16.
[0058] According to the grayscale values of the neighboring pixels of the original target pixel, the number of strong edge pixels among the neighboring pixels of the original target pixel, and the position distribution of the original target pixel and its neighboring pixels, the confidence of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image is obtained.
[0059] Preferably, as an embodiment of the present application, the maximum value of the grayscale value of all neighboring pixels of the original target pixel, the number of strong edge pixels among all neighboring pixels of the original target pixel, the average value of the distance between the original target pixel and all neighboring pixels, and the preset first constant are added together as the first cumulative sum of the original target pixel; the reciprocal of the first cumulative sum of the original target pixel is added together as the confidence of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image. In this embodiment, the value of the preset first constant is 0.01.
[0060] Specifically, the calculation formula for the sea surface temperature difference confidence of the target pixel is:
[0061] ;
[0062] In the formula, Indicates the confidence of the sea surface temperature difference of the target pixel; It represents the maximum gray value of all neighboring pixels of the original target pixel obtained by mapping the target pixel in the marine infrared image; It represents the average value of the distance between the original target pixel point and all neighboring pixel points obtained by mapping the target pixel point in the marine infrared image; It represents the number of strong edge pixels among all neighboring pixels of the original target pixel obtained by mapping the target pixel in the marine infrared image; Represents a preset first constant, and the value of the preset first constant is 0.01.
[0063] The sea surface temperature difference confidence of the target pixel is used to evaluate the possibility that the target pixel corresponds to the sea surface temperature difference position and the ship. When the maximum gray value of all neighboring pixels of the original target pixel, the number of strong edge pixels among all neighboring pixels of the original target pixel, and the distance between the original target pixel and all neighboring pixels are smaller, the sea surface temperature difference confidence of the target pixel is greater. At this time, the possibility that the target pixel corresponds to the position of uneven sea surface temperature is greater, and the possibility that the target pixel corresponds to the position of the ship is smaller.
[0064] The same method can be used to obtain the sea surface temperature difference confidence of any pixel point in the reconstructed marine infrared image. That is, for each pixel point in the reconstructed marine infrared image, there is a corresponding sea surface temperature difference confidence.
[0065] The sea surface temperature difference confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the first division threshold. The pixels whose sea surface temperature difference confidence in the reconstructed marine infrared image is greater than the first division threshold are recorded as pixels to be divided, and the pixels whose sea surface temperature difference confidence in the reconstructed marine infrared image is less than or equal to the first division threshold are recorded as suspicious ship pixels.
[0066] The pixel points to be divided correspond to the locations with uneven temperature on the sea surface or ships, and the suspicious ship pixel points correspond to ships on the sea surface.
[0067] At this point, the pixels to be divided and the pixels of suspicious ships are obtained. The flow chart of dividing the pixels to be divided and the pixels of suspicious ships is as follows: Figure 2 shown.
[0068] Step S003, determines the sea surface confidence of the target pixel according to the position distribution of all weak edge pixels and strong edge pixels in the vicinity of the pixel at the corresponding position of the target pixel in the marine infrared image, and divides the pixel to be divided into sea surface pixels and ship pixels according to the sea surface confidence of all pixels in the marine infrared image.
[0069] The pixel points to be divided are further divided, and the pixel points corresponding to the uneven temperature position of the sea surface and the position of the ship are divided.
[0070] There are temperature differences in the seawater at different locations, and the temperature difference at the junction of different temperatures is small. Therefore, there may be some weak edge pixels near the pixels to be divided at the location of uneven temperature on the sea surface, but the distribution of weak edge pixels will be relatively sparse. However, there are more dense weak edge pixels near the pixels to be divided at the location of the ship, and there are multiple strong edge pixels with a close distance around the weak edge pixels.
[0071] The DCP density clustering algorithm is used to process all weak edge pixels in the marine infrared image to obtain the local density of each weak edge pixel, where the cutoff distance of the DCP density clustering algorithm is 1% of the total number of edge feature points. It is a well-known technology to use the DCP density clustering algorithm to obtain the local density of pixels, which will not be described in detail.
[0072] The sea surface confidence of the target pixel is determined according to the number of weak edge pixels in the neighboring pixels of the original target pixel, the local density of the weak edge pixels, and the position distribution of the strong edge pixels in the local range of the original target pixel.
[0073] Preferably, as an embodiment of the present application, the original target pixel is taken as the central pixel, and a local window with a side length of the first preset threshold is established. In this embodiment, the value of the first preset threshold is 10. The local window of the original target pixel is taken as the local range of the original target pixel, and the cumulative sum of the Euclidean distances between all strong edge pixels and the original target pixel in the local window of the original target pixel is recorded as the second cumulative sum of the original target pixel. The number of weak edge pixels in the neighboring pixels of the original target pixel, the mean of the local density of the weak edge pixels, the number of strong edge pixels contained in the local window of the original target pixel and the preset first constant are recorded as the third cumulative sum of the original target pixel. The ratio of the second cumulative sum of the original target pixel to the third cumulative sum is recorded as the sea surface confidence of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image.
[0074] Specifically, the calculation formula for the sea surface confidence of the target pixel is:
[0075] ;
[0076] in, Indicates the sea surface confidence of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image; Represents the second accumulated sum of the original target pixel; Indicates the number of weak edge pixels in the neighboring pixels of the original target pixel; Represents the mean of the local density of weak edge pixels among the neighboring pixels of the original target pixel; Represents the number of strong edge pixels contained in the local window of the original target pixel; Represents a preset first constant, and the value of the preset first constant is 0.01.
[0077] The sea surface confidence of the target pixel is used to evaluate the possibility that the pixel to be divided corresponds to the position of the uneven temperature on the sea surface. When the second cumulative sum of the original target pixel is larger and the third cumulative sum is smaller, the sea surface confidence of the target pixel is larger. At this time, the possibility that the target pixel corresponds to the position of the uneven sea surface temperature is greater, and the possibility that the target pixel corresponds to the position of the ship is smaller.
[0078] The sea surface confidence of any pixel point in the reconstructed marine infrared image can be obtained in the same way, that is, for each pixel point in the reconstructed marine infrared image, there is a corresponding sea surface confidence.
[0079] The sea surface confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the second division threshold. The pixels in the reconstructed marine infrared image whose sea surface confidence is greater than the second division threshold are recorded as sea surface pixels, and the pixels in the reconstructed marine infrared image whose sea surface confidence is less than or equal to the second division threshold are recorded as ship pixels.
[0080] At this point, the sea surface pixels and ship pixels are obtained.
[0081] It can be understood that all pixels in the reconstructed marine infrared image are divided into three categories, namely, suspicious ship pixels, sea surface pixels and ship pixels.
[0082] Step S004, super-resolution reconstruction is performed on the reconstructed marine infrared image to obtain a high-resolution marine infrared image corresponding to the marine infrared image, and ships are identified based on all high-resolution marine infrared images.
[0083] Commonly used super-resolution reconstruction algorithms include bilinear interpolation and bicubic interpolation. Bilinear interpolation is simple to calculate, but it will cause high-frequency component loss and edge blur. Bicubic interpolation can obtain smoother image edges than bilinear interpolation, but it is computationally intensive and will take up a lot of memory resources. Most of the pixels in marine infrared images correspond to the sea surface, and only a small number of pixels correspond to ships. In order to make the edge of the ship clearer, the focus is placed on the ship during super-resolution reconstruction.
[0084] In order to make the super-resolution reconstructed ship have clear edges and not consume a lot of computing resources during the reconstruction process, this embodiment uses bilinear interpolation for sea surface pixels and bicubic interpolation for ship pixels.
[0085] The coordinate positions of the sea surface pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bilinear interpolation method to obtain the interpolation pixel value of each sea surface pixel in the reconstructed marine infrared image. The coordinate positions of the suspicious ship pixels and the ship pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bicubic interpolation method to obtain the interpolation pixel value of each suspicious ship pixel and each ship pixel in the reconstructed marine infrared image.
[0086] In order to ensure that the pixel value of each pixel in the acquired image is meaningful, the interpolated pixel values of all pixels in the reconstructed marine infrared image are rounded, and the values that exceed the pixel value range after rounding are assigned to obtain the adjusted pixel values of all pixels in the reconstructed marine infrared image. The specific process of assigning values that exceed the pixel value range is to assign rounded values greater than 255 to 255 and to assign rounded values less than 0 to 0.
[0087] The adjusted pixel values of all pixels in the reconstructed marine infrared image are used as the pixel values of the pixels to obtain a high-resolution marine infrared image.
[0088] At this point, high-resolution marine infrared images are obtained. It can be understood that each marine infrared image corresponds to a high-resolution marine infrared image.
[0089] The dataset consisting of all high-resolution infrared images is used as a high-quality training set for the ship recognition model so that the network can learn more accurate image features and improve the recognition accuracy of ships. It is understandable that the high-quality training set for the ship recognition model contains 1,000 high-resolution marine infrared images.
[0090] Specifically, the training process of the ship recognition model in this application is as follows: the high-resolution marine infrared image is preprocessed by normalization, that is, the image matrix is converted into , so that the model converges better. Then, the processed image data, the label corresponding to the image, and the mask marked by each pixel are sent to the network for training to learn the image features of different types of pixels in the high-resolution marine infrared image. In this embodiment, the pixels are divided into four categories: suspicious ship pixels, sea surface pixels, ship pixels, and other pixels. The label data is manually annotated, and the suspicious ship pixels, sea surface pixels, ship pixels, and other pixels are represented by 1, 2, 3, and 4, respectively. In this embodiment, the network structure of the recognition model is SSD (Single Shot MultiBox Detector), the optimizer is Adam (Adaptive MomentEstimation) optimizer, and the loss function includes the target classification loss function, that is, the multi-classification cross entropy function and the target positioning loss function. During training, the activation function uses the Softmax function.
[0091] The training process of a neural network is a well-known technology, and the specific process will not be described in detail.
[0092] By inputting the high-resolution marine infrared image corresponding to the marine infrared image that needs to be used for ship identification into the trained ship identification model, the category information and position information of each pixel in the high-resolution marine infrared image can be obtained, and the identification result of the ship in the high-resolution marine infrared image can be obtained.
[0093] At this point, ship recognition using high-resolution infrared simulation images has been achieved.
[0094] Based on the same inventive concept as the above method, an embodiment of the present invention also provides a ship identification system based on high-resolution infrared simulation images, including a memory, a processor, and a computer program stored in the memory and running on the processor, and when the processor executes the computer program, the steps of any one of the above-mentioned ship identification methods based on high-resolution infrared simulation images are implemented.
[0095] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A ship recognition method based on high-resolution infrared simulation images, characterized in that: The following steps are involved: Collect multiple marine infrared images for ship identification and analyze each marine infrared image separately; Detect the edge of the marine infrared image to obtain strong edge pixels and weak edge pixels, perform super-resolution reconstruction on the marine infrared image to obtain the reconstructed marine infrared image, record any pixel in the reconstructed marine infrared image as a target pixel, obtain the sea surface temperature difference confidence of the target pixel according to the gray value distribution and position distribution of the pixel in the vicinity of the corresponding position pixel in the marine infrared image, and the position distribution of the strong edge pixel, and divide the pixel to be divided and the pixel of the suspicious ship according to the sea surface temperature difference confidence of the pixel in the reconstructed marine infrared image; According to the position distribution of all weak edge pixels and strong edge pixels in the vicinity of the pixel at the corresponding position of the target pixel in the marine infrared image, the sea surface confidence of the target pixel is determined, and the pixel to be divided is divided into sea surface pixels and ship pixels according to the sea surface confidence of all pixels in the marine infrared image; Perform super-resolution reconstruction on the reconstructed marine infrared image to obtain a high-resolution marine infrared image corresponding to the marine infrared image, and identify ships based on all high-resolution marine infrared images; The specific method of obtaining the sea surface temperature difference confidence of the target pixel point according to the gray value distribution and position distribution of the pixel points in the vicinity of the corresponding position pixel point in the marine infrared image, and the position distribution of the strong edge pixel points, includes: According to the coordinates of the target pixel points in the reconstructed marine infrared image, the target pixel points are mapped to the marine infrared image to obtain the original target pixel points; According to the gray value of the neighboring pixels of the original target pixel, the number of strong edge pixels among the neighboring pixels of the original target pixel, and the position distribution of the original target pixel and the neighboring pixels, the confidence of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image is obtained; The specific method for obtaining the sea surface temperature difference confidence of the target pixel point is as follows: The pixel points in the marine infrared image that are closest to the original target pixel point in Euclidean distance by a second preset threshold are recorded as the neighboring pixel points of the original target pixel point; The maximum value of the grayscale value of all neighboring pixels of the original target pixel, the number of strong edge pixels among all neighboring pixels of the original target pixel, the average value of the distance between the original target pixel and all neighboring pixels, and a preset first constant are added together as the first accumulated sum of the original target pixel; the reciprocal of the first accumulated sum of the original target pixel is added together as the confidence of the sea surface temperature difference of the target pixel corresponding to the original target pixel in the reconstructed marine infrared image; The specific method for obtaining the sea surface confidence of the target pixel point is as follows: The original target pixel is taken as the central pixel, a local window with a side length equal to the first preset threshold is established, and the cumulative sum of the Euclidean distances between all the strong edge pixels in the local window of the original target pixel and the original target pixel is recorded as the second cumulative sum of the original target pixel; The number of weak edge pixels in the neighboring pixels of the original target pixel, the average of the local density of the weak edge pixels, the number of strong edge pixels contained in the local window of the original target pixel, and a preset first constant are accumulated and recorded as the third accumulated sum of the original target pixel; The ratio of the second cumulative sum to the third cumulative sum of the original target pixel point is recorded as the sea surface confidence of the target pixel point corresponding to the original target pixel point in the reconstructed marine infrared image; The specific method of dividing the pixels to be divided into sea surface pixels and ship pixels according to the sea surface confidence of all pixels in the marine infrared image is as follows: The sea surface confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the second division threshold; The pixel points whose sea surface confidence in the reconstructed marine infrared image is greater than the second division threshold are recorded as sea surface pixel points, and the pixel points whose sea surface confidence in the reconstructed marine infrared image is less than or equal to the second division threshold are recorded as ship pixel points; The super-resolution reconstruction of the reconstructed marine infrared image to obtain a high-resolution marine infrared image corresponding to the marine infrared image includes the following specific methods: The coordinate positions of the sea surface pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bilinear interpolation method to obtain the interpolation pixel value of each sea surface pixel in the reconstructed marine infrared image; the coordinate positions of the suspicious ship pixels and the ship pixels in the reconstructed marine infrared image and the gray values of all the pixels in the marine infrared image are used as the input of the bicubic interpolation method to obtain the interpolation pixel value of each suspicious ship pixel and each ship pixel in the reconstructed marine infrared image; The interpolated pixel values of all the pixels in the reconstructed marine infrared image are adjusted to obtain the adjusted pixel values of all the pixels, and the adjusted pixel values of all the pixels in the reconstructed marine infrared image are used as the pixel values of the pixels to obtain a high-resolution marine infrared image; The interpolation pixel values of all pixels in the reconstructed marine infrared image are adjusted to obtain the adjusted pixel values of all pixels, including the following specific methods: The interpolated pixel values of all the pixels in the reconstructed marine infrared image are rounded, and the rounded values greater than 255 are assigned to 255, and the rounded values less than 0 are assigned to 0, so as to obtain the adjusted pixel values of all the pixels in the reconstructed marine infrared image; The specific method of identifying ships based on all high-resolution marine infrared images includes: The data set consisting of all high-resolution infrared images is used as a high-quality training set for the ship recognition model, and the SSD target detection network is trained to obtain the ship recognition model; The high-resolution marine infrared image corresponding to the marine infrared image that needs to be used for ship identification is input into the trained ship identification model to obtain the category information and position information of each pixel in the high-resolution marine infrared image, and obtain the recognition result of the ship in the high-resolution marine infrared image.
2. The ship recognition method based on high-resolution infrared simulation images according to claim 1 is characterized in that: The specific method of dividing the pixels to be divided and the suspicious ship pixels is: The sea surface temperature difference confidence of all pixels in the reconstructed marine infrared image is processed using the Otsu threshold algorithm to obtain the first division threshold; The pixel points whose sea surface temperature difference confidence in the reconstructed marine infrared image is greater than the first division threshold are recorded as pixels to be divided, and the pixel points whose sea surface temperature difference confidence in the reconstructed marine infrared image is less than or equal to the first division threshold are recorded as suspicious ship pixels.
3. A ship identification system based on high-resolution infrared simulation images, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, the steps of the ship recognition method based on high-resolution infrared simulation images as described in any one of claims 1-2 are implemented.
Citation Information
Patent Citations
Civil security engineering monitoring method based on computer vision
CN116311079A
Infrared ship positioning method based on row suppression
CN117115193A