Deep Learning for Rainfall Similarity Analysis
Deep Learning for Rainfall Similarity Analysis
sciences
Article
Rainfall Similarity Search Based on Deep Learning by Using
Precipitation Images
Yufeng Yu * , Xingu He, Yuelong Zhu and Dingsheng Wan
Abstract: Precipitation images play an important role in meteorological forecasting and flood fore-
casting, but how to characterize precipitation images and conduct rainfall similarity analysis is
challenging and meaningful work. This paper proposes a rainfall similarity research method based
on deep learning by using precipitation images. The algorithm first extracts regional precipitation,
precipitation distribution, and precipitation center of the precipitation images and defines the similar-
ity measures, respectively. Additionally, an ensemble weighting method of Normalized Discounted
Cumulative Gain-Improved Particle Swarm Optimization (NDCG-IPSO) is proposed to weigh and
fuse the three extracted features as the similarity measure of the precipitation image. During the exper-
iment on similarity search for daily precipitation images in the Jialing River basin, the NDCG@10 of
the search results reached 0.964, surpassing other methods. This indicates that the method proposed
in this paper can better characterize the spatiotemporal characteristics of the precipitation image,
thereby discovering similar rainfall processes and providing new ideas for hydrological forecasting.
Keywords: precipitation image; feature extraction; similarity analysis; multivariate feature fusion;
Improved Particle Swarm Optimization
1. Introduction
In recent years, flash floods caused by extreme rainfall have led to extensive social
Citation: Yu, Y.; He, X.; Zhu, Y.; Wan,
and economic losses [1]. Due to the influence of precipitation intensity, precipitation
D. Rainfall Similarity Search Based
distribution, and other factors, there are many uncertainties in the time, location, grade,
on Deep Learning by Using and process of floods, which pose great obstacles to early flood warning and prevention.
Precipitation Images. Appl. Sci. 2023, Therefore, extracting spatiotemporal features of rainfall-runoff processes, identifying and
13, 4883. [Link] classifying them, so as to discover similar rainfall-flood patterns from historical rainfall
app13084883 events to provide guidance and technical support for hydrological forecasting and water
resource utilization, has become an urgent task in the application field of hydrology and
Academic Editor: Yu-Dong Zhang
water resources [2,3].
Received: 22 February 2023 The rainfall-flood similarity analysis uses fuzzy mathematics, data mining, and ma-
Revised: 8 April 2023 chine learning methods to identify the similar (closest) sequence pairs to the current
Accepted: 10 April 2023 real-time rainfall-flood sequence from the historical hydrological time series patterns by
Published: 13 April 2023 defining the similarity measure [4]. The most direct application of rainfall-flood similarity
analysis is to determine whether a current rainfall-flood process is similar or equivalent to
a process in a historical period [5]. In this sense, research on similarity analysis methods
has significant potential for rainfall-runoff process forecasting, environmental evolution
Copyright: © 2023 by the authors.
analysis, and hydrological regularity discovery [6,7].
Licensee MDPI, Basel, Switzerland.
Rainfall similarity analysis is an important part of rainfall-flood similarity analysis
This article is an open access article
and flood risk assessment [8]. It can not only discover the rules of similar rainfall-flood
distributed under the terms and
conditions of the Creative Commons
patterns in history but also provide new ideas and technical support for rainfall-flood
Attribution (CC BY) license (https://
forecasting. Zhang [9] established a similarity analysis model for precipitation stations
[Link]/licenses/by/
using the K-means clustering algorithm based on the Davies–Bouldin index. Then the
4.0/). single precipitation type histogram similarity model was adapted to analyze the clustering
Figure
[Link]
Exampleofofprecipitation
precipitation image.
Thispaper
This paperproposes
proposesaa rainfall
rainfall similarity
similarity research
researchmethod
methodbasedbasedonondeep
deeplearning
learningbyby
using precipitation images. The novelty of this article lies in that the regional precipitation,
using precipitation images. The novelty of this article lies in that the regional precipitation,
precipitation distribution, and precipitation center are extracted as the characters of the
precipitation distribution, and precipitation center are extracted as the characters of the
precipitation image, and then appropriate distance measures for each feature are defined
precipitation image, and then appropriate distance measures for each feature are defined
to better characterize the similarity between images. After that, an ensemble weighting
tomethod
better characterize the similarity between images. After that, an ensemble weighting
of normalized depreciation cumulative gain-improved particle swarm optimization
method of normalized
(NDCG-IPSO) is proposed depreciation
to weight cumulative
and fuse the gain-improved
distance measuresparticle
of swarm optimiza-
three extracted
tion
features as the similarity measure for daily precipitation image similarity search. three ex-
(NDCG-IPSO) is proposed to weight and fuse the distance measures of
tractedThe
features as the
remaining similarity
part measure
of this paper for daily
is organized asprecipitation
follows: Section image similarity
2 presents search.
the related
The
work remaining
to this part of this
area of research. paper
Section is organized
3 presents the briefasoffollows:
NDCG-IPSO. Section 2 presents
Several the re-
experiments
lated work to this area of research. Section 3 presents the brief of NDCG-IPSO.
with the proposed method using real-world precipitation images are reported in Section 4. Several
experiments with
Finally, Section the conclusions
5 gives proposed and method using for
suggestions real-world precipitation images are
further research.
Appl. Sci. 2023, 13, 4883 3 of 14
2. Related Studies
2.1. Image Feature Extraction
Feature extraction (FE) is an important and necessary step in many processes related
to image retrieval [13], image encryption [14], and pattern recognition [15], which was used
to extract the most distinct and useful information presented in an image dataset, to form a
low-dimensional feature space to represent and describe the images for the next searching,
browsing, or retrieving. Generally, color, shape, and texture are common characteristics
extracted for image retrieval [16].
As shown in Figure 1, the precipitation image has similar shape and texture features.
Therefore, only the color features are extracted to characterize the different precipitation
images. In this paper, the global color histogram is used to extract the color features of
the precipitation image, and the regional precipitation of the basin is calculated according
to the practical significance of each color. Moreover, the image is divided into m*n grids,
and the block color histogram is used to extract more detailed information, such as spatial
distribution and rainfall center, for a better description of the precipitation image.
t +1 t t +1
expressed as the vector xi = [xi1 , xi2 , . . . x, ixiD=] and
xi +vvi =
i [vi1 , vi2 , . . . , viD ], respectively. The(2)
position of the particle is updated as follows:
The speed of the ith particle is updated as follows from iteration number to iteration
xit+1 = xit + vit+1 (2)
number +1:
The speed of the 𝑣ith particle
= 𝑤𝑣 is+updated
𝑐 𝑟 𝑝 as follows
− 𝑥 +from 𝑐 𝑟 iteration
𝑝 − 𝑥number to iteration(3)
number +1:
vit+weight,
1
= wvit which t − xit the r2 ptgbest −degree
xit
where w is the inertia + c1 r1 represents
pibest + c2retention of the particle (3)
to the
last velocity; c1 is the individual learning factor, which represents the learning ability of
where w is the inertia weight, which represents the retention degree of the particle to the
the particle to the individual optimal solution. c2 is the social learning factor, which rep-
last velocity; c1 is the individual learning factor, which represents the learning ability of the
resents the learning ability of the particle to the current optimal solution of the population.
particle
t
to the individual optimal solution. c2 is the social learning factor,
t
which represents
pibestlearning
the is the individual optimal
ability of the particlesolution foundoptimal
to the current time t; pof
by pi at solution theispopulation.
gbest the population
pt op- ibest
is thesolution
individual optimal solution by pi at time t;atp gbest t
timal found by the wholefound
population particle timeist. the population
In addition, theoptimal
algorithm
solution found by the whole population particle at time t. In addition, the algorithm
also has a parameter to represent the population size, that is, the number of particles, alsoand
has a parameter to represent the population size, that is, the number
a parameter to represent the maximum number of iterations of the algorithm. of particles, and a
parameter to represent the maximum number of iterations of the algorithm.
3. Rainfall Similarity Search Based on NDCG-IPSO
3. Rainfall Similarity Search Based on NDCG-IPSO
The performance of the image search system crucially depends on the feature repre-
The performance of the image search system crucially depends on the feature rep-
sentation
resentationandandsimilarity measurement.
similarity [Link],
Therefore,the process
the processofofprecipitation
precipitationimage
imagesim-
ilarity
similarity search mainly consists of two steps. Firstly, three features, namely the regionalpre-
search mainly consists of two steps. Firstly, three features, namely the regional
cipitation, thethe
precipitation, precipitation
precipitationdistribution,
distribution, and the precipitation
and the precipitationcenter,
center,areare extracted
extracted fromfrom
the historical precipitation images and stored in the historical database. Then,
the historical precipitation images and stored in the historical database. Then, the above the above
three featuresare
three features areextracted
extracted from
from the the precipitation
precipitation imageimage to be queried,
to be queried, and theand thewith
images images
with
higherhigher similarity
similarity valuesvalues are retrieved
are retrieved from thefrom the historical
historical images asimages as the similarity
the similarity query
[Link].
query The process flow of flow
The process precipitation image matching
of precipitation is shown is
image matching in shown
Figure 2.
in Figure 2.
Feature Extraction
Precipitation
Distribution
Regional
Precipitation DB
Precipitation
Historical
Center
Precipitation Images
Precipitation
Distribution
Similarity Similarity query results
Regional
Matching
Precipitation
Based on
Precipitation NCDG-IPSO
Query precipitation
Center
image
Feature Extraction
Figure 2.
Figure The process
2. The process flow
flowof
ofprecipitation
precipitationimage
imagesearching.
searching.
3.1. Feature Extraction
3.1.1. Regional Precipitation
Regional precipitation usually represents the total amount of precipitation within
a given area at a specific time. In the precipitation image, each color corresponds to a
range of precipitation amount. Hence, the regional precipitation feature can be obtained
by weighting the color histogram, which can record the frequency of each color in the
precipitation image.
weighting the color histogram, which can record the frequency of each color in the pre-
cipitation image.
Let the color histogram corresponding to the precipitation image contain K colors,
namely C1, C2, ..., CK, the occurrence number of each color in the image is num(Ci) (1 ≤ i ≤
Appl. Sci. 2023, 13, 4883 K), and the precipitation amount corresponding to each color is pm(Ci), then the5 regional
of 14
precipitation within a given area can be calculated as follows:
K
Let the color histogram corresponding
P = num
namely C1 , C2 , . . . , CK , the occurrence inumber
=1
to (the
Ci ) precipitation
pm ( Ci ) image contain K colors, (4)
of each color in the image is num(Ci )
(1 ≤ i ≤ K), and the precipitation amount corresponding to each color is pm(Ci ), then the
Moreover,
regional let P1within
precipitation and P2abe the area
given regional precipitation
can be calculated asfeature
follows:of the two precipitation
images. The defined Manhattan distance Dp to measure the similarity between the re-
K images can be calculated as follows:
gional precipitation features of the two
P = ∑ num(Ci ) pm(Ci ) (4)
i =1
D = P1 − P2
Moreover, let P1 and P2 be the regionalP precipitation feature of the two precipitation (5)
images. The defined Manhattan distance Dp to measure the similarity between the regional
precipitation features of the two images can be calculated as follows:
3.1.2. Precipitation Distribution
DP = | P1 − P2 | (5)
Regional precipitation can roughly represent the total amount of regional precipita-
tion within
3.1.2. a givenDistribution
Precipitation area, but it is difficult to reflect the spatial distribution characteristics
of precipitation.
Regional precipitation canthe
Therefore, block-based
roughly color
represent histogram
the total amountisofused to divide
regional the water-
precipitation
shed image into rectangular blocks with m rows and n columns after truncating
within a given area, but it is difficult to reflect the spatial distribution characteristics of redundant
annotation. That
precipitation. is, the the
Therefore, precipitation
block-based image
colorishistogram
divided into m*ntosmall
is used divide grids. Additionally,
the watershed
the regional precipitation for each small grid can be calculated
image into rectangular blocks with m rows and n columns after truncating redundantaccording to formula (4),
respectively. Let P be the regional precipitation for the grid located
annotation. That is, the precipitation image is divided into m*n small grids. Additionally,
(i, j) at the ith row and
the regional
the j column.
th The precipitation
precipitation for eachdistribution
small grid canmatrix, denoted according
be calculated as R, is defined to character-
to formula (4),
ize the spatial
respectively. P(i, j) be the regional
Letdistribution feature precipitation
for the precipitation image,
for the grid which
located ith be
at thecan rowcalculated
and the as
th column. The precipitation distribution matrix, denoted as R, is defined to characterize
jfollows:
the spatial distribution feature for the precipitation image, which can be calculated as
follows: P(1,1) , P(1,2) ,…, P(1,n )
P(1,1), PP(1,2, P) , . . ,.…
,P
(2,1) ( 2,2) ,P 2, n )
((1,n )
PR =
(2,1), P(2,2) , . . . , P(2,n) (6)
R= (6)
P(m,1) , P · ·,… · ,P
P(m,1), P(m,2)(,m ,2. ). . , P((m,nm,n )
)
Figure
Figure33shows
showsthe
theprecipitation
precipitationdistribution matrix
distribution after
matrix blocking
after operation
blocking for the
operation for the
precipitation image.
precipitation image.
[Link]
Figure Theprecipitation
precipitationdistribution
distribution matrix.
matrix.
Let R(a, b) be one of the blocks around R(i, j) in image B, where a ∈ {i − 1, i, i + 1}, b ∈ {j − 1,
j, j + 1}. Let DAB(i, j) be the distance between elements in the ith row and the jth column of
precipitation distribution matrix RA and RB , which can be calculated using the method
shown in Figure 4. If the distance between RA(i, j) and RB(i, j) , denoted as D1 , is smaller than
that between RA(i, j) and RB(a, b) (a ∈ {i − 1, i, i + 1}, b ∈ {j − 1, j, j + 1}), denoted as D2 , DAB(i, j)
can be represented by D1 , else DAB(i, j) is represented by the mean of D1 and D2 .
Thus, the distance of the precipitation distributions of two precipitation images, de-
fined as DR, can be calculated as follows:
DR = i =1 j =1DAB( i, j )
m n
(7)
Appl. Sci. 2023, 13, 4883 6 of 14
Thus, the distance of the precipitation distributions of two precipitation images, de-
3.1.3. Precipitation Center
fined as DR , can be calculated as follows:
Flood processes are largely influenced by the precipitation center. When the precipi-
tation center is located upstream of the watershed, ∑im=1long
DR = the ∑nj=1 D
distance
AB(i,j) to the watershed (7)
section leads to a long lag time for the flood peak and presents a short and plump flood
3.1.3. Precipitation Center
process. Meanwhile, when the precipitation center is located downstream, the short dis-
Flood processes are largely influenced by the precipitation center. When the precipita-
tance to the watershed section will make it a short lag time for the flood peak and form a
tion center is located upstream of the watershed, the long distance to the watershed section
sharp and thin flood hydrograph.
leads to a long lag Hence, it is
time for theimportant
flood peakto take
and the precipitation
presents centerflood
a short and plump as process.
a major feature in the precipitation
Meanwhile, when image similaritycenter
the precipitation research. Combined
is located downstream,with the actualdistance to
the short
precipitation situation and image
the watershed similarity
section retrieval
will make requirements,
it a short lag time for the take thepeak
flood blockandwith
form a sharp
and thin flood
the maximum precipitation hydrograph.
in the precipitationHence,
imageit isafter
important
beingtodivided
take theinto
precipitation
blocks ascenter as a
major feature in the precipitation image similarity research. Combined with the actual
the precipitation center.
precipitation situation and image similarity retrieval requirements, take the block with the
Let P(i, j) be the maximum precipitation of the blocks in the precipitation image, then
maximum precipitation in the precipitation image after being divided into blocks as the
the precipitation center C(i, j) could be the block at the ith row and the jth column. Let C(i1, j1)
precipitation center.
and C(i2, j2)be the precipitation
Let P(i, j)centers of two precipitation
be the maximum precipitationimages. The in
of the blocks Euclidean distance
the precipitation image, then
C(i,two th
at the iwhich j column. Let th
Dc is defined as thethe precipitation
difference between centerthe j) could be the block
precipitation centers, row and thecalcu-
can be
C(i1 , j1 ) and C(i2 , j2 ) be the precipitation centers of two precipitation images. The Euclidean
lated as follows:
distance Dc is defined as the difference between the two precipitation centers, which can be
calculated as follows: q
2
D C = ( i1 − i2)
DC+ = ) 2 i2 )2 + ( j1 − j2 )2
( j1 −(ij12 − (8) (8)
where γ1 , γ2, and γ3 are undetermined coefficient weights for the distance of regional
precipitation, precipitation distribution, and precipitation center.
There are three kinds of methods namely the subjective weight method, objective
weight method, and subjective-objective comprehensive weight method, to determine the
undetermined coefficient. Subjective weighting relies on expert’s experiential knowledge,
leading to subjectivity and variability. Objective weighting depends on the problem domain
cipitation, precipitation distribution, and precipitation center.
There are three kinds of methods namely the subjective weight method, objective
weight method, and subjective-objective comprehensive weight method, to determine the
undetermined coefficient. Subjective weighting relies on expert’s experiential knowledge
Appl. Sci. 2023, 13, 4883
leading to subjectivity and variability. Objective weighting depends on the 7problem of 14
do
main and sample data, but its results are poorly interpretable with low persuasiveness
Integration weighting methods can combine subjective and objective features, compen
and sample data, but its results are poorly interpretable with low persuasiveness. Integra-
sating for the shortcomings of both approaches [25].
tion weighting methods can combine subjective and objective features, compensating for
The NDCG-IPSO
the shortcomings of bothisapproaches
a new subjective–objective
[25]. comprehensive weight method pro
posedThe to NDCG-IPSO
improve theisefficiency of precipitation image
a new subjective–objective comprehensive similarity
weightsearches, which use
method pro-
IPSO
posed totoadjust
improvethe the
weight of multiple
efficiency indicators
of precipitation to make
image the evaluation
similarity resultsuses
searches, which close to the
evaluation results by experts based on subjective experience, and then applies the NDCG
IPSO to adjust the weight of multiple indicators to make the evaluation results close to the
asevaluation
indicatorsresults by experts
to evaluate based
the imageon subjective experience,
search results and then
weighted applies thefeatures.
by multiple NDCG asThe pro
indicators to evaluate the image search results weighted by multiple features.
cess of the NDCG-IPSO is shown in Figure 5. The method combines the advantages The process of the
of the NDCG-IPSO is shown in Figure 5. The method combines the advantages of the
objective weighting method and the subjective weighting method and makes the
objective weighting method and the subjective weighting method and makes the weighting
weighting
result meetresult meet the requirements
the requirements in theand
in the way of fitting way of fitting and approximation.
approximation.
Figure5.
Figure Flow chart
5. Flow chartofofNDCG-IPSO.
NDCG-IPSO.
3.2.1. Evaluation Metrics
3.2.1. Evaluation Metrics
NDCG is used as the metric to evaluate the image search results weighted by multiple
NDCG
features, is used asthe
representing the metric to value
normalized evaluateof the the image search
discounted results
cumulative weighted
gain [26]. Sup- by multi
ple features, representing the normalized
pose a batch similarity search task is for E 1 , E 2value of
, . . . , E n the discounted cumulative
. The search result for E 1 is e , e
i1 i2 gain
, [26]
. . .
Suppose, e . Each
ik a batche in the results is another entity that the search system considers to be
ij similarity search task is for E1, E2, …, En. The search result for E1 is ei1, ei2 similar
to ethe
…, entity E , which has a real score of similarity degree with E . The cumulative gain of
ik. Each eij iin the results is another entity that the searchi system considers to be simila
the K term before the search result of entity Ei is defined as CGi @K, which can be calculated
to the entity Ei, which has a real score of similarity degree with Ei. The cumulative gain o
as follows:
the K term before the search result of entity EKi is defined as CGi@K, which can be calculated
CGi @K = ∑ relij (10)
as follows: j =1
DCG discounts the gain of the lower-ranked items to have a significant influence on
the gain for the top-ranked items in the search result list. The cumulative loss gain of K
term before entity Ei search result DCG@K is calculated as follows:
K relij
DCGi @K = ∑ log2 ( j+1) (11)
j =1
Appl. Sci. 2023, 13, 4883 8 of 14
The normalized correlation coefficient is the DCG@K value of the ideal search result,
denoted as IDCG@K, and the calculation formula of NDCG@K is as follows:
DCGi @K
NDCGi @K = IDCGi @K (12)
where wmax is the initial maximum inertia weight, wmin is the minimum inertia weight
when iterating to the maximum algebra, kmax is the maximum number of iterations, and
w(k) is the inertia weight value when iterating for k times.
• Learning ratio c1 and c2 ;
Parameters c1 and c2 represent the ability of a particle to learn from the individual
and the group optimal solution, respectively, and usually take the same value between 0
and 4 based on experience. Moreover, if c1 takes a large value and c2 takes a small value
in the early stages of the iteration it can enhance the global search ability of the particles.
Meanwhile, if c1 takes a small value and c2 takes a large value in the later stages of the
iteration, it can improve the local search ability of particles. Therefore, IPSO improves
parameters c1 and c2 with the symmetric linear strategy [27] to optimize the learning
ability of individual optimal solutions and group optimal solutions for particles. The
improvements in c1 and c2 are presented as follows:
where [Link] and [Link] represent the initial and termination values of c1 , so do [Link] and
[Link] . ∆c represents the maximum variable length of c1 and c2 ; cmid is the middle value of
c1 and c2 .
Figure 6. Location
Figure 6. Locationofofthe
theJialing
Jialing Basin.
Basin.
To verify
To verifythe theNDCG-IPSO
NDCG-IPSO method
methodfor image similarity
for image search,
similarity daily precipitation
search, daily precipitation
images from Jialing Basin from 1 January 2010, to 12 December 2019, were used for training
images from Jialing Basin from 1 January 2010, to 12 December 2019, were used for train-
and validation. Therefore, the experiment chose 30 precipitation images with different rain-
ing
fall and validation.
grades (6 images Therefore,
of light rain,the experiment
9 images choserain,
of moderate 30 precipitation
and 15 imagesimages with
of heavy different
rain)
rainfall grades (6 images of light rain, 9 images of moderate rain, and
as the query samples and 10 matching samples for each query sample from the historical15 images of heavy
rain) as the query
precipitation [Link] and 10
Additionally, matching
each matchingsamples for each
sample was query
assigned sample from
a similarity score the his-
torical
from 0 precipitation image.
(totally dissimilar) Additionally,
to 2 (very similar)each matching
according sample
to expert was assigned
experience a similarity
to measure
how similar the query sample and the matched sample were. In the experiment, the
score from 0 (totally dissimilar) to 2 (very similar) according to expert experience to meas- query
samples
ure howwere
similardivided into thesample
the query trainingand
sample
theset and test sample
matched sample set according
were. In thetoexperiment,
the ratio the
of 2:1.
query samples were divided into the training sample set and test sample set according to
the
[Link] ofAnalysis
Results 2:1.
The NDCG-IPSO was used to conduct image similarity search experiments on the daily
precipitation images of the Jialing Basin. γ1 , γ2 , and γ3 were initialized randomly, and their
sum was guaranteed to be 1. The inertia weight w was set to 0.9, which linearly decreases to
0.4 as the number of iterations increases according to the Formula (13). Individual learning
factors c1 and social learning factors c2 were set at 2.5 and 1.25. The particle number and
the iteration number of the IPSO were set to 30 and 80 to obtain the optimal parameters of
multi-feature distances for the precipitation image, which was shown in Table 1.
Table 1. Optimal weights of the three feature distances for precipitation image.
Feature Distance γ1 γ2 γ3
coefficient 0.46 0.12 0.42
Table 2. Optimal weights of the three feature distances for precipitation image.
Accuracy
Images NDCG@5 NDCG@10
As seen in Table 2, the NDCG-IPSO can obtain higher index values on both training
and test samples. Particularly, the average accuracy of NDCG@5 and NDCG@10 of the
method on the test samples were 0.978 and 0.964, respectively, which were very close to
1. The experimental results prove the following two points: On the one hand, the three
features extracted in this paper can well represent the spatial and temporal characteristics
of the precipitation image and meet the needs of the precipitation image analysis, which can
be used as indicators for image similarity of daily precipitation images. On the other hand,
the NDCG-IPSO has a good effect on fusing feature distances defined in this paper into
the comprehensive distance and thus quickly retrieves similar images from precipitation
images.
Figure 7 shows the similarity search results of the precipitation image based on the
NDCG-IPSO. For the precipitation image to be queried in the first line shown in Figure 7,
pl. Sci. 2023, 13, x FOR PEER REVIEW lines 2 and 3 display the top 10 images that are very similar in terms of regional precipitation, 11 of
precipitation distribution, and precipitation center, which can prove the effectiveness of this
method and provide technical support for the analysis of similar hydrological processes.
Figure 7. Image
Figure search
7. Image results
search results of NDCG-IPSO.
of NDCG-IPSO.
Accuracy
NDCG@5 NDCG@10
Appl. Sci. 2023, 13, 4883 11 of 14
Accuracy
Method NDCG@5 NDCG@10
A color histogram is widely used in many image retrieval systems, which search
similar images by extracting color histograms in images and calculating the distance
between the histograms. Considering that precipitation images mainly adopt color features
to represent different precipitation information, the color histogram is perhaps the most
suitable method for precipitation image similarity searches. The global CH [28] and the
block CH [29] with 3 × 3 blocks are used to search similar precipitation images. The results
shown in Table 3 indicate that though global CH it can well characterize the color features
of precipitation images, it ignores the spatial information of color features and results in
low accuracy of similarity retrieval. The block CH considers part of the spatial information,
and its searching accuracy is better than that of the global CH. However, block CH does
not consider the physical meaning of the different colors on the precipitation image, which
leads to worse searching accuracy than that of NDCG-IPSO.
The PCA and BORDA are two commonly used multi-index comprehensive evaluation
methods, which are also widely used in the mining of multivariate hydrological similarity.
The PCA conducts principal component analysis on all three feature distances and takes
the feature with cumulative variance contribution rates greater than 85% as the principal
component, and then weighs the features according to their variance contribution rates
to obtain the search results after sorting. The BORDA sorts the feature distance once and
synthesizes the similarity search results of those feature distances by BORDA to obtain the
final query result. Although PCA, BORDA and NDCG-IPSO extract precipitation spatial
distribution, precipitation center, and regional precipitation and comprehensively consider
three distances to search similar images, NDCG-IPSO uses machine learning algorithms to
optimize ensemble weighing method parameters and thus achieves better results than that
of PCA and BORDA.
The only difference between NDCG-PSO and NDCG-IPSO is that the latter adopts the
inertia weight and two learning factors in the PSO algorithm with an increase in the number
of iterations. This adaptive adjustment improves the search performance and accuracy
of the NDCG-IPSO. Figure 8 shows the fitness function value, namely NDCG@5, varying
with the number of iterations in the NDCG-PSO and NDCG-IPSO. It can be seen from
Figure 8 that NDCG-IPSO obtains the optimal particle fitness of 0.984 after 18 iterations;
while NDCG-PSO gets stuck in a local optimum of 0.959 after 27 iterations. This indicates
that IPSO can improve the search accuracy and optimization speed of image similar search
and thus provides support for improving similar precipitation image retrieval.
curacy of the NDCG-IPSO. Figure 8 shows the fitness function value, namely NDCG@5,
varying with the number of iterations in the NDCG-PSO and NDCG-IPSO. It can be seen
from Figure 8 that NDCG-IPSO obtains the optimal particle fitness of 0.984 after 18 itera-
tions; while NDCG-PSO gets stuck in a local optimum of 0.959 after 27 iterations. This
indicates that IPSO can improve the search accuracy and optimization speed of image
Appl. Sci. 2023, 13, 4883 12 of 14
similar search and thus provides support for improving similar precipitation image re-
trieval.
[Link]
Figure Comparisonofof experimental
experimental results
results between
between PSOPSO algorithm
algorithm and IPSO
and IPSO algorithm.
algorithm.
5. Conclusions
5. Conclusions
This paper proposes a rainfall similarity research method based on deep learning by
This paper proposes a rainfall similarity research method based on deep learning by
using precipitation images. Firstly, the regional precipitation, precipitation distribution,
using
and precipitation
precipitation images.
center Firstly, the
are extracted fromregional precipitation,
the precipitation precipitation
images, distribution,
and the similarity
and precipitation center are extracted from
measurement for each feature is calculated separately. the precipitation images, and the similarity
measurement for each feature is calculated separately.
Additionally, an ensemble weighting method of normalized depreciation cumulative
Additionally,
gain-improved an ensemble
particle weighting(NDCG-IPSO)
swarm optimization method of normalized
is proposed depreciation
to weigh and cumulative
fuse
the three extracted features as the similarity measure of the precipitation image. Finally,and
gain-improved particle swarm optimization (NDCG-IPSO) is proposed to weigh the fuse
the three extracted
comparing experimentfeatures as the with
of our method similarity
CH, PCA,measure
BORDA,of the
andprecipitation
NDCG-PSO on image. Finally,
the daily
precipitation
the comparingimages in the Jialing
experiment River
of our Basin illustrates
method with CH,thatPCA, theBORDA,
methods proposed in this on
and NDCG-PSO
paper can better
the daily characterize
precipitation the spatiotemporal
images characteristics
in the Jialing River of the precipitation
Basin illustrates image pro-
that the methods
and discover similar rainfall processes, which will provide a new idea for hydrological
posed in this paper can better characterize the spatiotemporal characteristics of the pre-
forecasting.
cipitation image and discover similar rainfall processes, which will provide a new idea for
Althoughforecasting.
hydrological some achievements have been made, many problems must still be solved.
One problem is that it only considers the daily precipitation images similarity searching.
Although some achievements have been made, many problems must still be solved.
However, a rainfall process may be composed of multiple single-day precipitation images.
One problem is that it only considers the daily precipitation images similarity searching.
Hence, how to conduct the rainfall process similarity search based on the similarity
However, a rainfall process may be composed of multiple single-day precipitation images.
measurement method of NDCG-PSO and thus build a rainfall-flood similarity pattern
Hence,
repository to how to conduct
provide guidancethe andrainfall process
technical similarity
support search based
for hydrological on the similarity
forecasting and
measurement method of NDCG-PSO and thus build
water resource utilization is the direction of our future work. a rainfall-flood similarity pattern
Author Contributions: Conceptualization, Y.Y.; Methodology, Y.Y., X.H., Y.Z. and D.W.; Software,
X.H.; Validation, Y.Z.; Formal analysis, X.H.; Writing—original draft, X.H.; Writing—review & editing,
Y.Y. and D.W.; Visualization, X.H.; Supervision, Y.Y., Y.Z. and D.W.; Project administration, Y.Y., Y.Z.
and D.W. All authors have read and agreed to the published version of the manuscript.
Funding: This research was funded by the National Key R&D Program of China (No. 2021YFB3900605
and 2018YFC1508100).
Institutional Review Board Statement: Not applicable.
Informed Consent Statement: Not applicable.
Data Availability Statement: Not applicable.
Acknowledgments: The authors would like to thank the Bureau of Hydrology, Changjiang water
Resources Commission, especially Chen Yubin and Zhang Xiao, for their great help in data provision,
algorithm design, and model training of this paper.
Conflicts of Interest: The authors declare no conflict of interest.
Appl. Sci. 2023, 13, 4883 13 of 14
References
1. Li, B.; Liang, Z.; Bao, Z.; Wang, J.; Hu, Y. Changes in streamflow and sediment for a planned large reservoir in the middle Yellow
River. Land Degrad. Dev. 2019, 30, 878–893. [CrossRef]
2. Stenta, H.R.; Riccardi, G.A.; Basile, P.A. Grid size effects analysis and hydrological similarity of surface runoff in flatland basins.
Hydrol. Sci. J. 2017, 62, 1736–1754. [CrossRef]
3. Liang, Z.; Xiao, Z.; Wang, J.; Sun, L.; Li, B.; Hu, Y.; Wu, Y. An improved chaos similarity model for hydrological forecasting. J.
Hydrol. 2019, 577, 123953. [CrossRef]
4. Dilmi, D.; Barthès, L.; Mallet, C.; Aymeric, C. Modified DTW for a quantitative estimation of the similarity between rainfall time
series. EGU Gen. Assem. 2017, 19, EGU2017-16005.
5. Xiao, Z.; Liang, Z.; Li, B.; Hou, B. New flood early warning and forecasting method based on similarity theory. J. Hydrol. Eng.
2019, 24, 04019023. [CrossRef]
6. Barthel, R.; Haaf, E.; Giese, M.; Nygren, M.; Heudorfer, B.; Stahl, K. Similarity-based approaches in hydrogeology: Proposal of a
new concept for data-scarce groundwater resource characterization and prediction. Hydrogeol. J. 2021, 29, 1693–1709. [CrossRef]
7. Wang, H.; Xing, C.; Yu, F. Study of the hydrological time series similarity search based on Daubechies wavelet transform. In
Unifying Electrical Engineering and Electronics Engineering, Proceedings of the 2012 International Conference on Electrical and Electronics
Engineering, London, UK, 4–6 July 2012; Springer: New York, NY, USA, 2013; pp. 2051–2057.
8. Yang, J.; Wan, D.; Yu, Y. Similarity Search Method of Hydrological Time Series based on Fragment Alignment Distance and Dynamic
Time Warping. In Proceedings of the IEEE 2022 5th International Conference on Advanced Electronic Materials, Computers and
Software Engineering (AEMCSE), Wuhan, China, 22–24 April 2022; pp. 214–220.
9. Zhang, L.; Zhu, Y.; Li, S.; Gao, X. Study on Similarity Model of Precipitation Series Based on Precipitation Type Histogram. J.
China Hydrol. 2013, 33, 10–16.
10. Ohno, G.; Kazunori, I. Flood Forecast Based on Deep Learning Using Distribution MAP of Precipitation. In Proceedings of the
22nd IAHR APD Congress, Sapporo, Japan, 14–17 September 2020.
11. Wang, X.; Liu, Y.; Chen, Y.; Liu, Y. An adaptive density-based time series clustering algorithm: A case study on rainfall patterns.
ISPRS Int. J. Geo-Inf. 2016, 5, 205. [CrossRef]
12. Gang, J.; Zhao, W. RETRACTED ARTICLE: Remote sensing image-based rainfall changes in plain areas and IoT motion image
detection. Arab. J. Geosci. 2021, 14, 1–17. [CrossRef]
13. Pradhan, J.; Kumar, S.; Pal, A.K.; Banka, H. Texture and colour region separation based image retrieval using probability annular
histogram and weighted similarity matching scheme. IET Image Process. 2020, 14, 1303–1315. [CrossRef]
14. Wu, Y.; Zhang, L.; Berretti, S.; Wan, S. Medical Image Encryption by Content-Aware DNA Computing for Secure Healthcare.
IEEE Trans. Ind. Inform. 2023, 19, 2089–2098. [CrossRef]
15. Divakar, R.; Singh, B.; Bajpai, A.; Kumar, A. Image pattern recognition by edge detection using discrete wavelet transforms. J.
Decis. Anal. Intell. Comput. 2022, 2, 26–35.
16. Alsmadi, M.K. Content-based image retrieval using color, shape and texture descriptors and features. Arab. J. Sci. Eng. 2020, 45,
3317–3330. [CrossRef]
17. Kumbure, M.M.; Luukka, P. A generalized fuzzy k-nearest neighbor regression model based on Minkowski distance. Granul.
Comput. 2022, 7, 657–671. [CrossRef]
18. Gassouma, M.S.; Benhamed, A.; El Montasser, G. Investigating similarities between Islamic and conventional banks in GCC
countries: A dynamic time warping approach. Int. J. Islam. Middle East. Financ. Manag. 2023, 16, 103–129. [CrossRef]
19. Ristad, E.S.; Yianilos, P.N. Learning String-Edit Distance. IEEE Trans. Pattern Anal. Mach. Intell. 1997, 20, 522–532. [CrossRef]
20. Benti, N.E.; Chaka, M.D.; Semie, A.G. Forecasting Renewable Energy Generation with Machine learning and Deep Learning:
Current Advances and Future Prospects. [Link] 2023, 2023030451. [CrossRef]
21. Zhang, L.; Zhang, B. Deep learning for remote sensing data: A technical tutorial on the state of the art. IEEE Geosci. Remote Sens.
Mag. 2016, 4, 22–40. [CrossRef]
22. Frana, R.P.; Monteiro, A.; Arthur, R.; Lano, Y. An overview of deep learning in big data, image, and signal processing in the
modern digital age. Trends Deep. Learn. Methodol. 2021, 63–87. [CrossRef]
23. Wu, Y.; Guo, H.; Chakraborty, C.; Khosravi, M.; Berretti, S.; Wan, S. Edge Computing Driven Low-Light Image Dynamic
Enhancement for Object Detection. IEEE Trans. Netw. Sci. Eng. 2022, 3151502. [CrossRef]
24. Kennedy, J.; Eberhart, R. Particle swarm optimization. In Proceedings of the ICNN’95-International Conference on Neural
Networks, Perth, WA, Australia, 27 November–1 December 1995; Volume 4, pp. 1942–1948.
25. Paramanik, A.R.; Sarkar, S.; Sarkar, B. OSWMI: An Objective-Subjective Weighted method for Minimizing Inconsistency in
multi-criteria decision making. Comput. Ind. Eng. 2022, 169, 108138. [CrossRef]
26. Furui, K.; Ohue, M. Compound virtual screening by learning-to-rank with gradient boosting decision tree and enrichment-based
cumulative gain. In Proceedings of the 2022 IEEE Conference on Computational Intelligence in Bioinformatics and Computational
Biology (CIBCB), Ottawa, ON, Canada, 15–17 August 2022; pp. 1–7.
27. Feng, K.; Li, X.; Qian, X.; Wu, L.; Zheng, H.; Chen, M.; Li, M.; Liu, B. Atmospheric Optical Turbulence Profile Model Fitting Based
on Improved Particle Swarm Algorithm. Laser Optoelectron. Prog. 2022, 59, 73–84.
28. Liu, C.; Sui, X.; Kuang, X.; Liu, Y.; Gu, G.; Chen, Q. Optimized Contrast Enhancement for Infrared Images Based on Global and
Local Histogram Specification. Remote Sens. 2019, 11, 849. [CrossRef]
Appl. Sci. 2023, 13, 4883 14 of 14
29. Li, K.; Sun, X.; Gao, B.; Zhou, J. Weighted Histogram Block Detection Algorithm for Digital Trunking Terminal. In Proceedings of
the International Conference on Intelligent Automation and Soft Computing, Chicago, IL, USA, 28–30 May 2021; Springer: Cham,
Switzerland, 2021; pp. 166–172.
30. Muhammad, M.; Oscar, V. Pairwise consensus and the Borda rule. Math. Soc. Sci. 2022, 116, 17–21.
31. Boudou, A.; Viguier-Pla, S. Principal components analysis and cyclostationarity. J. Multivar. Anal. 2022, 189, 104875. [CrossRef]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual
author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to
people or property resulting from any ideas, methods, instructions or products referred to in the content.