1 模型
Robust small target detection of low signal-to-noise ratio (SNR) is very important in infrared search and track applications for self-defense or attacks. Consequently, an effective small target detection algorithm inspired by the contrast mechanism of human vision system and derived kernel model is presented in this paper. At the first stage, the local contrast map of the input image is obtained using the proposed local contrast measure which measures the dissimilarity between the current location and its neighborhoods. In this way, target signal enhancement and background clutter suppression are achieved simultaneously. At the second stage, an adaptive threshold is adopted to segment the target. The experiments on two sequences have validated the detection capability of the proposed target detection method. Experimental evaluation results show that our method is simple and effective with respect to detection accuracy. In particular, the proposed method can improve the SNR of the image significantly.
2 部分代码
clear all; close all; clc; % cd 'D:\Small target detection\code\code3\MS_LCM-master'; % 改路径后即可直接运行!!! % 读取测试图像 I_read = imread('test.bmp'); % 检测RGB,转为灰度图 Channel_test = size(size(I_read)); if Channel_test(1,2) == 2 I_in = I_read; else I_in = rgb2gray(I_read); end % 显示输入图像,转为double型 % imshow(I_in); % imtool(I_in); I_in = double(I_in); % 计算最终的Multiscale LCM,注意这张图小于原始图像,最大的patch为27*27,因此比原始图像小26 [C_hat,max_margin] = MLCM_computation(I_in); % 计算均值、标准差 mean_C_hat = mean(C_hat(:)); % 矩阵均值 sqrt_C_hat = (sqrt_matrix(C_hat,mean_C_hat))^0.5; % 标准差 % 计算阈值 k_Th = 4; threshold = mean_C_hat + k_Th*sqrt_C_hat; % 根据阈值判断,输出二值探测结果和统计小目标在mask中占据的像元数 [I_out,target_pixel_num] = target_detection(C_hat,threshold,max_margin,I_in); % 显示输入和输出 figure() subplot(1,2,1); imshow(I_in,[0,255]),impixelinfo; title('原图'); subplot(1,2,2); imshow(I_out),impixelinfo; title('二值化输出');
3 仿真结果
4 参考文献
[1] Chen, C. , Li, H. , Wei, Y. , Xia, T. , & Tang, Y. Y. . (2013). A local contrast method for small infrared target detection. IEEE Transactions on Geoscience & Remote Sensing, 52(1), 574-581.