{'fraction_non_alphanumeric': 0.02178617804068677, 'fraction_numerical': 0.005266195354205742, 'mean_word_length': 5.112433862433862, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Research on Dynamic Measurement Method of Electromagnetic Environment Based on Image Similarity

In this paper, by discretizing the battlefield region, using the power, frequency and direction of the wave to quantitatively characterize the electromagnetic environment, the image similarity measure, the gray histogram comparison and the signal arrival direction histogram method are introduced to analyze the histogram. The degree of change of the graph is proposed, and a calculation method for calculating the degree of change of electromagnetic environment is proposed. The method is simulated. The comparison of the histograms at different time points proves that the method has certain effectiveness in dealing with various electromagnetic environments.


Introduction
Since the degree of change of the electromagnetic environment needs to show the time adaptive situation to recognize [1,2], how to quantitatively measure the degree of electromagnetic environment change is very important. In many electromagnetic environment measurement methods, there is a lack of measurement of the dynamics of the electromagnetic environment [3]. Therefore, this paper proposes a method to calculate the degree of electromagnetic environment change to measure the dynamics of the electromagnetic environment of the battlefield, discretize the battlefield region, quantitatively characterize the electromagnetic environment by power, frequency and direction of arrival, and introduce image similarity measure and gray scale. Histogram comparison and signal-towave direction histogram method, the region is divided by grid, so that the characterization of the whole electromagnetic environment is transformed into a representation of the discrete point electromagnetic effect set.

Spectrum characteristics based on signal strength and incoming wave direction
After the regional electromagnetic environment is characterized as a matrix form, it is similar to the data structure of the bitmap: the separation of two-dimensional space [4,5]. The scatter is similar to a pixel, and the spectral features described by EMEW are similar to RGB or HSV color spaces [6]. This introduces the concept of spectral feature map: a representation of the spectral characteristics of the region [7]. The spectral characteristics of the point are described by the electromagnetic signal strength and the direction of the incoming wave at discrete points. The set of all discrete points constitutes the characteristic description of the regional electromagnetic environment [8]. After 2 considering the regional electromagnetic environment as the spectrum feature map, the method of measuring image similarity can be introduced to measure the similarity of the electromagnetic environment of the same region at two time points. The degree of change ΔE of the regional electromagnetic environment can be described as: Where Δ represents the similarity measure of the electromagnetic environment at time t and t+Δt, and the value interval is [0, 1]. Then the rate of change of the electromagnetic environment with respect to time: Similar to the definition of displacement and velocity, the degree of change and rate of change can effectively describe the dynamics of the electromagnetic environment [9]. Different from the description method in the image field (each pixel of the bitmap can be described by only one set of feature vectors [10]). In the electromagnetic environment representation of this paper, there may be more than one kind of signal at the discrete points, the characteristics of the electromagnetic wave. There may be several combinations of frequencies and intensities at each point. Strictly speaking, if there are n frequencies points in the area under investigation, then there are n spectrum feature maps corresponding to them, that is, each frequency point corresponds to one spectrum feature map. In view of this feature, this paper subdivides the spectral grayscale image by slice method, and cuts the shortwavelength band of 3M~30M into n slices with the bandwidth of (30M-3M)/n, and each spectrum slice corresponds to one spectral grayscale image. After the slicing method, the degree of change of the entire frequency band can be comprehensively measured by calculating the similarity of each spectral feature map.   Table 1. Assuming that the radiation range is horizontal omnidirectional, the propagation loss is calculated using the propagation model in free space, and the signal intensity at each point is normalized to the gray scale of [0, 1] to form the spectral grayscale image shown in Fig. 2a. The direction of the small arrow at each discrete point in Figure 2b represents the direction of the incoming wave affected by the source at that point, which contains the location information of the source.

Spectral feature histogram and its distance metric
For the two spectral feature bitmaps defined in the previous section, this section will give the construction method of the corresponding histogram and the measure of the distance of the histogram vector.
(1) Signal strength histogram The signal strength histogram is calculated by discretizing the gray level representing the signal intensity and counting the number of pixel points falling into each discrete gray level. Since gray scale is a mapped value of signal strength, this method of calculating similarity by gray histogram can be called similarity calculation based on signal intensity statistical histogram, which can measure the change of radiation source power, radiation range change, The electromagnetic environment changes caused by the silent opening of the radiation source and the change of the position of the radiation source.
The calculation steps are described as follows: Step 1 grayscale discretization. The gray value is discretized to [0, N], N is a positive integer, and N+1 is a gray scale number.
Step 2 establishes a grayscale histogram feature vector. Let the vector represent the gray feature vector, Where g(i) represents the number of pixels of gray scale i.
Step 3 counts the grayscale histogram. In the signal intensity grayscale map A, For each element g(i) in its histogram feature vector , N+1 is the discretized gray scale number, u represents the pixel point in the grayscale image A, b∈{1, 2,..., N+1}, and u represents the grayscale index value at the pixel point u , is the Kronecker function of the gray scale i.
(2) Incoming wave direction histogram If only the histogram representing the signal strength is considered, the calculation result may be insensitive to the movement of the radiation source. As shown in Fig. 3, it is assumed that the radiation source moves from point A to point B, and point C is on the vertical line of the line AB. If By discretizing the wave direction in the future, a histogram representing the statistical characteristics of the incoming wave direction can be constructed. Since the direction of the incoming wave is determined by the relative position of the radiation source and the measured point, the histogram of the incoming wave direction can simply and effectively describe the distribution characteristics of the radiation source. And location changes. The steps to construct a histogram are as follows: Step 1 calculates the direction of the arrival of the discrete points in the affected area according to the radiation source position . Define the angle of the incoming wave as the angle θ between the vector and the positive direction of the x-axis: When and , or , θ When , or and , θ Where , indicating the distance between the radiation source and the measured point.
In addition, when there are multiple radiation source signals in a certain discrete point, there are multiple incoming wave directions at the point. The difference in the number of radiation sources may cause the inconsistent icon degrees of the incoming wave direction to be inconsistent. Therefore, measures need to be taken to synthesize multiple incoming wave directions. So that each point corresponds to at most one direction. In order to increase the weight of the signal with higher intensity, the parallelogram rule for calculating the direction of the resultant force in classical mechanics can be borrowed when synthesizing the direction of the incoming wave.
Step 2 discretizes the continuous incoming wave direction. The direction of the incoming wave calculated according to step (1) is a continuous angle, which needs to be mapped into a discrete set. Discretize the continuous real region of [0, 2 ) and divide it into M intervals. The interval numbers are from 1 to M, and the range of each interval is 2 /M.
Step 3 statistics the direction of the wave is straight. Let the vector denote the eigenvector of the histogram of the incoming wave direction, where h(i) represents the direction of the incoming wave The number of pixels in the i interval. Similar to the algorithm of equation , in the incoming wave pattern A, for each element h(i) in its histogram feature vector , (6) M is the number of gray scales after discretization, u represents the pixel point in the wave pattern A, ∈{1,2,...,M} represents the direction index of the incoming wave at the pixel point u, is The kronecker function of the wave direction i.
(3) Distance measurement method of histogram vector Some features of the electromagnetic environment are described by histograms. The distance between the histogram vectors can be used to measure the degree of change of the electromagnetic environment. For the two n-dimensional vectors X and Y, the quadratic distance is introduced to calculate the electromagnetic environment characteristic histogram distance: (4) Multi-slice fusion After calculating the degree of change of each slice, the degree of change of the entire frequency band of interest can be comprehensively measured according to a certain algorithm. Common methods include arithmetic average method and weighted average method. Although the arithmetic average comprehensively examines the variation factors of each slice, it cannot capture the dramatic changes of one or a few slices, especially in the case of a large number of slices; if the weighted average method is used, the weight of each slice is difficult. determine. Therefore, the squared average method can be used to fuse the calculation results of each slice to form a comprehensive measure of the degree of variation of the frequency band, namely: (8) Where D represents the degree of comprehensive change, Di represents the degree of change of slice i, and n represents the number of slices. The squared average can appropriately highlight the effect of severely varying slices on the overall degree of change.

Simulation analysis
For the study of the degree of change on a single slice at a fixed frequency point, factors such as increased radiation source reduction, radiation source position change, and power variation should be considered. In the simulation experiments in this section, considering these factors, several typical cases are designed to analyze the comparison between the signal intensity histogram and the incoming wave histogram in different situations. Using the short-wave transmitter parameters in the Wrap software standard station database, since the electromagnetic environment calculation is not the focus of this paper, in order to simplify the calculation, this paper constructs a two-dimensional space simulation environment in Matlab7.1, regardless of terrain factors, to freedom. The spatial propagation model calculates the signal strength. This experimental method can be extended to three-dimensional space, but more discrete points need to be calculated, and the length of the feature vector remains unchanged. In practical applications, it is necessary to combine real terrain and environmental conditions to obtain more accurate calculation results.
The process of electromagnetic environment change is designed in a square area with a side length of 100Km, which is divided into four moments. The radiation source position and parameter information of these four moments are shown in Table 2. It includes factors such as increase, decrease, movement, and power variation of the radiation source to analyze changes in the single slice.  The lengths of the two histograms are set to 200, and the radiation source distribution, the signal intensity histogram, and the incoming wave direction histogram at four moments are shown in Fig. 4. At time 1 there are 2 radiation sources at 28MHz and 4 radiation sources at 3 other times. We set different radiation source position or parameter data for these four moments, and contain some special cases (such as radiation). The source position is symmetrically changed, etc.), and it is hoped to verify the metric proposed in this paper. Comparing the histograms of time 1 and the other 3 moments, the signal intensity histogram and the incoming wave direction histogram are greatly different due to the change of the number of radiation sources; compared with time 2 and time 3, since the position of the radiation source is unchanged, Only the power changes, so the difference between the signal intensity histograms is larger, and the incoming wave direction histograms are similar. Compared with time 2 and time 4, the power of the four radiation sources is the same, but the position changes, so the signal intensity histogram the change is not large, and the histogram of the incoming wave varies greatly.
From the comparison of histograms at different times, the histogram changes are in accordance with the simulation, and the two histograms are complementary. Even under extreme conditions, the combination of two histograms can effectively measure the degree of change. The method has certain effectiveness in dealing with various electromagnetic environments.