CN116679080A - River surface flow velocity determining method and device and electronic equipment - Google Patents
River surface flow velocity determining method and device and electronic equipment Download PDFInfo
- Publication number
- CN116679080A CN116679080A CN202310631562.5A CN202310631562A CN116679080A CN 116679080 A CN116679080 A CN 116679080A CN 202310631562 A CN202310631562 A CN 202310631562A CN 116679080 A CN116679080 A CN 116679080A
- Authority
- CN
- China
- Prior art keywords
- search line
- target
- space
- determining
- preset
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 39
- 238000005311 autocorrelation function Methods 0.000 claims abstract description 47
- XLYOFNOQVPJJNP-UHFFFAOYSA-N water Substances O XLYOFNOQVPJJNP-UHFFFAOYSA-N 0.000 claims abstract description 42
- 238000004364 calculation method Methods 0.000 claims abstract description 29
- 230000009466 transformation Effects 0.000 claims abstract description 8
- 238000005070 sampling Methods 0.000 claims description 29
- 230000015654 memory Effects 0.000 claims description 19
- 238000006243 chemical reaction Methods 0.000 claims description 13
- 239000002352 surface water Substances 0.000 claims description 11
- 238000004590 computer program Methods 0.000 claims description 3
- 238000005259 measurement Methods 0.000 description 6
- 238000010586 diagram Methods 0.000 description 5
- 239000002245 particle Substances 0.000 description 4
- 239000012530 fluid Substances 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 238000001228 spectrum Methods 0.000 description 3
- 230000007547 defect Effects 0.000 description 2
- 239000011159 matrix material Substances 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000000037 particle-tracking velocimetry Methods 0.000 description 2
- 230000010363 phase shift Effects 0.000 description 2
- 239000000700 radioactive tracer Substances 0.000 description 2
- 239000007787 solid Substances 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 239000003086 colorant Substances 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000007613 environmental effect Effects 0.000 description 1
- 238000000691 measurement method Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000003595 spectral effect Effects 0.000 description 1
- 230000002123 temporal effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01P—MEASURING LINEAR OR ANGULAR SPEED, ACCELERATION, DECELERATION, OR SHOCK; INDICATING PRESENCE, ABSENCE, OR DIRECTION, OF MOVEMENT
- G01P5/00—Measuring speed of fluids, e.g. of air stream; Measuring speed of bodies relative to fluids, e.g. of ship, of aircraft
- G01P5/18—Measuring speed of fluids, e.g. of air stream; Measuring speed of bodies relative to fluids, e.g. of ship, of aircraft by measuring the time taken to traverse a fixed distance
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01P—MEASURING LINEAR OR ANGULAR SPEED, ACCELERATION, DECELERATION, OR SHOCK; INDICATING PRESENCE, ABSENCE, OR DIRECTION, OF MOVEMENT
- G01P5/00—Measuring speed of fluids, e.g. of air stream; Measuring speed of bodies relative to fluids, e.g. of ship, of aircraft
- G01P5/18—Measuring speed of fluids, e.g. of air stream; Measuring speed of bodies relative to fluids, e.g. of ship, of aircraft by measuring the time taken to traverse a fixed distance
- G01P5/22—Measuring speed of fluids, e.g. of air stream; Measuring speed of bodies relative to fluids, e.g. of ship, of aircraft by measuring the time taken to traverse a fixed distance using auto-correlation or cross-correlation detection means
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02A—TECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
- Y02A90/00—Technologies having an indirect contribution to adaptation to climate change
- Y02A90/30—Assessment of water resources
Landscapes
- Engineering & Computer Science (AREA)
- Aviation & Aerospace Engineering (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Image Analysis (AREA)
Abstract
The application discloses a river surface flow rate determining method, a device and electronic equipment, wherein the method comprises the steps of generating a space-time image of a preset search line in a target river, carrying out Fourier transformation on the space-time image to obtain a two-dimensional autocorrelation function of the space-time image, determining coordinate values corresponding to a plurality of target pixel points with correlation values larger than the preset value in the space-time image based on the two-dimensional autocorrelation function, carrying out coordinate transformation on the coordinate values corresponding to each target pixel point to obtain a polar coordinate value corresponding to each target pixel point, determining the water flow direction of the target river surface based on the polar coordinate value of each target pixel point, and calculating the flow rate of the target river according to the water flow direction of the target river surface, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line. The method provided by the application realizes accurate calculation of the water flow direction, and can accurately calculate the river surface flow velocity based on the water flow direction.
Description
Technical Field
The application relates to the technical field of flow velocity measurement, in particular to a river surface flow velocity determining method and device and electronic equipment.
Background
The prior art generally uses the large scale particle tracking velocimetry (large-scale particle tracking velocimetry, LSPTV) method to velocity river flow, which works on the principle of shining a laser beam onto a fluid sample and measuring the phase shift of the laser beam as it passes through the sample, which phase shift is related to the velocity of particles or droplets in the fluid, which can then be used to calculate the velocity and flow of the fluid, meaning that the accuracy of the measurement depends on the distribution of the tracer particles in the water, which may be affected by various factors such as wind, turbulence and other environmental conditions.
Furthermore, in areas with complex flow patterns (e.g., rapid flow, waterfall, and high turbulence areas), the use of artificial tracer particles is also more challenging. In areas with complex flow patterns, the distribution of the trace particles may vary widely, and it is therefore difficult to obtain accurate and reliable measurements. Therefore, the scheme of measuring river flow rate by adopting the existing LSPTV has the defect of inaccurate measurement results.
Disclosure of Invention
Therefore, the technical problem to be solved by the application is to overcome the defect that the measurement result of the conventional LSPTV speed measurement method for river flow rate measurement scheme is not accurate enough, so as to provide a river surface flow rate determination method, a river surface flow rate determination device and electronic equipment.
In a first aspect, an embodiment of the application discloses a river surface flow rate determining method, which is used for acquiring gray information corresponding to a plurality of sampling times of a preset search line in a target river; generating a space-time image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, wherein the space-time image is used for representing the association relationship between the gray value of each pixel point on the search line and the sampling time as well as the length of the search line; performing Fourier transform on the space-time images of the search lines to obtain a two-dimensional autocorrelation function corresponding to the space-time images, wherein the two-dimensional autocorrelation function of the space-time images is used for representing the correlation between the gray value of each pixel point in the space-time images and the gray values of other pixel points; determining coordinate values corresponding to a plurality of target pixel points with correlation values larger than a preset value in the space-time image based on a two-dimensional autocorrelation function; coordinate conversion is carried out on the coordinate value corresponding to each target pixel point, and polar coordinate values of each target pixel point are obtained; determining a target river surface water flow direction based on the polar coordinate value of each target pixel point; and calculating the surface flow rate of the target river according to the flow direction of the water flow on the surface of the target river, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line.
According to the river surface flow rate determining method/device, the space-time image of the preset search line in the target river is generated, fourier transformation is carried out on the space-time image to obtain a two-dimensional autocorrelation function of the space-time image, coordinate values corresponding to a plurality of target pixels with correlation values larger than the preset value in the space-time image are determined based on the two-dimensional autocorrelation function, coordinate conversion is carried out on the coordinate values corresponding to each target pixel to obtain polar coordinate values corresponding to each target pixel, the direction of the water flow of the target river surface is determined based on the polar coordinate values of each target pixel, and the target river surface flow rate is calculated according to the water flow direction of the target river surface, the space-time image of the search line and real distance information corresponding to each pixel in the search line. According to the method provided by the application, the autocorrelation function can be obtained by carrying out Fourier transform on the space-time image, the inclination of the inclined stripes in the space-time image can be calculated based on the autocorrelation function, the inclination of the inclined stripes in the space-time image can be used for representing the direction of water flow, the accurate calculation of the water flow direction is realized, and the river surface flow rate can be accurately calculated based on the water flow direction.
With reference to the first aspect, in one possible implementation manner of the first aspect, after calculating the target river surface flow rate according to the target river surface water flow direction, the space-time image of the search line, and the real distance information corresponding to each pixel point in the search line, the method further includes: and determining the flow value in the preset calculation interval according to the surface flow rate of the target river and the area of the preset calculation interval of the target river.
The method provided by the embodiment can accurately calculate the flow value in the preset interval.
With reference to the first aspect, in one possible implementation manner of the first aspect, acquiring gray information corresponding to a plurality of sampling times of a preset search line in a target river includes: acquiring video data of a preset position in a target river; determining a preset search line based on the video data; and determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line.
With reference to the first aspect, in a possible implementation manner of the first aspect, determining the target river surface water flow direction based on the polar coordinate value of each pixel point of the target area includes: determining the gradient of stripes in the space-time image based on the polar coordinate value of each pixel point of the target area; determining the water flow direction on the search line based on the stripe gradient in the space-time image; the target river surface water flow direction is determined based on the water flow direction on the search line.
With reference to the first aspect, in a possible implementation manner of the first aspect, the two-dimensional autocorrelation function is obtained by:
wherein x represents the abscissa of the pixel in the spatiotemporal image, t represents the ordinate of the pixel in the spatiotemporal image, f (x, t) represents the gray value of the pixel in the spatiotemporal image, (τ) x ,τ t ) Offset parameter representing pixel point in spatio-temporal image, R (τ x ,τ t ) Is a two-dimensional autocorrelation function.
In a second aspect, the embodiment of the application also discloses a river surface flow rate determining device, which comprises: the acquisition module is used for acquiring gray information corresponding to a plurality of sampling times of a preset search line in a target river; the generation module is used for generating a space-time image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, wherein the space-time image is used for representing the association relationship between the gray value of each pixel point on the search line, the sampling time and the length of the search line; the first determining module is used for carrying out Fourier transformation on the space-time images of the search lines to obtain a two-dimensional autocorrelation function corresponding to the space-time images, and the two-dimensional autocorrelation function of the space-time images is used for representing the correlation between the gray value of each pixel point in the space-time images and the gray values of other pixel points; the second determining module is used for determining coordinate values corresponding to a plurality of target pixel points with the correlation values larger than a preset value in the space-time image based on the two-dimensional autocorrelation function; the coordinate conversion module is used for carrying out coordinate conversion on the coordinate value corresponding to each target pixel point to obtain the polar coordinate value of each target pixel point; the third determining module is used for determining the water flow direction of the surface of the target river based on the polar coordinate value of each target pixel point; the first calculation module is used for calculating the target river surface flow rate according to the flow direction of the target river surface water flow, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line.
With reference to the first aspect, in a possible implementation manner of the first aspect, the apparatus further includes: and the second calculation module is used for determining the flow value in the preset calculation interval according to the surface flow rate of the target river and the area of the preset calculation interval of the target river.
With reference to the first aspect, in a possible implementation manner of the first aspect, the acquiring module includes: the acquisition sub-module is used for acquiring video data of a preset position in the target river; the first determining submodule is used for determining a preset search line based on video data; and the second determining submodule is used for determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line.
In a third aspect, an embodiment of the present application further discloses an electronic device, including: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to cause the at least one processor to perform a river surface flow rate determination method as in the first aspect or any of the alternative embodiments of the first aspect.
In a fourth aspect, embodiments of the present application also disclose a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements a river surface flow rate determination method as in the first aspect or any of the alternative embodiments of the first aspect.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are needed in the description of the embodiments or the prior art will be briefly described, and it is obvious that the drawings in the description below are some embodiments of the present application, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart showing a specific example of a river surface flow rate determination method according to an embodiment of the present application;
FIG. 2 is a schematic diagram of search line positions in a river surface flow rate determination method according to an embodiment of the present application;
FIG. 3 is a schematic diagram of spatiotemporal images in a method of determining river surface flow rate in accordance with an embodiment of the present application;
FIG. 4 is a schematic block diagram of a specific example of a river surface flow rate determination apparatus in accordance with an embodiment of the application;
fig. 5 is a schematic diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made apparent and fully in view of the accompanying drawings, in which some, but not all embodiments of the application are shown. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
In the description of the present application, it should be noted that the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. The specific meaning of the above terms in the present application will be understood in specific cases by those of ordinary skill in the art.
In addition, the technical features of the different embodiments of the present application described below may be combined with each other as long as they do not collide with each other.
The embodiment of the application discloses a river surface flow rate determining method, which is shown in fig. 1 and comprises the following steps:
step S101, gray information corresponding to a plurality of sampling times of a preset search line in a target river is acquired.
The target river may be any river for which the river surface flow rate is to be determined, and the specific content of the target river is not limited in the embodiment of the present application, and may be determined by those skilled in the art according to requirements. The preset search line may be a straight line set along the river flow direction in the video of the target river acquired in advance, and in the embodiment of the present application, the position of the preset search line may be shown in the position of the line segment a in fig. 2, and the preset search line may be 165 pixels in length and one pixel in width. The gray information corresponding to the sampling times of the preset search line in the target river can be the gray information on the search line in the 165 continuous images selected from the video of the target river acquired in advance.
Step S102, generating a space-time image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, wherein the space-time image is used for representing the association relationship between gray values of each pixel point on the search line, the sampling time and the length of the search line.
For example, gray information corresponding to a plurality of sampling times of a preset search line is arranged according to a time sequence to generate a spatiotemporal image, in this embodiment of the present application, a schematic diagram of the spatiotemporal image may be shown in fig. 3, a t-axis in fig. 3 represents time (frame number), an x-axis represents a length of the search line, and a shade of a color in the figure represents a gray value of a pixel point in the spatiotemporal image.
And step S103, carrying out Fourier transformation on the space-time images of the search lines to obtain a two-dimensional autocorrelation function corresponding to the space-time images, wherein the two-dimensional autocorrelation function of the space-time images is used for representing the correlation between the gray value of each pixel point in the space-time images and the gray values of other pixel points.
In an embodiment of the present application, a two-dimensional autocorrelation function of a spatio-temporal image may be obtained by calculation based on wiener-Xin Qinding theory, where wiener-Xin Qinding theory indicates that a power spectral density of a signal is an amplitude square of fourier transform of the signal, and fourier transform is performed on a pixel point matrix in the spatio-temporal image to obtain a two-dimensional spectrum, where the two-dimensional spectrum characterizes energy distribution conditions of the spatio-temporal image in different spatial and temporal frequencies. And performing inverse Fourier transform on the two-dimensional frequency spectrum to obtain a two-dimensional autocorrelation function, wherein the two-dimensional autocorrelation function can express the similarity and predictability of pixel gray values at different positions and times in the image.
Step S104, determining coordinate values corresponding to a plurality of target pixel points with correlation values larger than a preset value in the space-time image based on the two-dimensional autocorrelation function.
The preset value may be any autocorrelation function value, and the specific content of the preset value is not limited in the embodiment of the present application, and may be determined by those skilled in the art according to requirements. In the embodiment of the application, the preset value may include, but is not limited to, 0.4, in order to better determine coordinate values corresponding to a plurality of target pixels with correlation values greater than the preset value in the space-time image, an autocorrelation function image may be drawn based on the autocorrelation function, the origin position is set as a maximum point of the autocorrelation function, the maximum point is used as a center to be displayed in a symmetrical unfolding manner, and different colors are used to represent the magnitude of the correlation value, so that a plurality of target pixels with correlation values greater than the preset value in the space-time image may be better determined, and further, coordinate values of the target pixels may be determined.
Step S105, coordinate conversion is performed on the coordinate values corresponding to each target pixel point, so as to obtain polar coordinate values of each target pixel point.
In an exemplary embodiment of the present application, in order to determine the fringe inclination angle of the large R-value region corresponding to the plurality of target pixel points, coordinate system conversion is performed on the coordinates of each target pixel point, so as to obtain the polar coordinate value of each target pixel point.
Step S106, determining the water flow direction of the surface of the target river based on the polar coordinate value of each target pixel point.
As an optional embodiment of the present application, step S106 specifically includes:
and a step a1, determining the gradient of the stripes in the space-time image based on the polar coordinate value of each pixel point of the target area. Illustratively, in the embodiment of the present application, the fringe inclination in the spatio-temporal image can be obtained by the following calculations of formulas (1), (2) and (3);
max(ρ)=min(max(τ x ),max(τ t )) (2)
wherein R (ρ, θ) represents the polar coordinates of the target pixel point, the absolute value R is the integral along the polar axis at different angles, R (ρ, θ) is the autocorrelation coefficient at polar coordinates, F (θ) is the integral of R (ρ, θ) for t different angles, τ x ,τ t The offsets in the x and t directions in the spatio-temporal image matrix are shown, respectively.
θ=argmax[F(θ)] (3)
Where arg denotes a complex argument, F (θ) reaches a maximum value P when θ is equal to the tilt angle of the large R value region.
And a step a2, determining the water flow direction on the search line based on the stripe gradient in the space-time image. Illustratively, in embodiments of the present application, the direction of water flow on the search line is equal to the stripe inclination in the spatio-temporal image.
Step a3, determining the water flow direction of the surface of the target river based on the water flow direction on the search line.
Illustratively, in embodiments of the present application, the target river surface water flow direction is equal to the water flow direction on the search line.
Step S107, calculating the surface flow rate of the target river according to the flow direction of the water flow on the surface of the target river, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line.
In the embodiment of the present application, assuming that the distance that the water path flow feature moves along the search line in the time T is L, the corresponding i pixels move in k frames under the phase plane coordinate system, the flow velocity on the search line may be calculated based on the following formula (4):
wherein θ represents an angle between a water flow direction of the surface of the target river and a reference direction, which may be determined based on a general direction of the water flow, S x Representing the true distance (in m/pixel) represented by each pixel, fps represents the frame rate (in frames/s) of the camera. The target river surface flow rate may be determined based on the flow rate on the search line.
According to the river surface flow rate determining method, a space-time image of a preset search line in a target river is generated, fourier transformation is carried out on the space-time image to obtain a two-dimensional autocorrelation function of the space-time image, coordinate values corresponding to a plurality of target pixel points with correlation values larger than the preset value in the space-time image are determined based on the two-dimensional autocorrelation function, coordinate conversion is carried out on the coordinate values corresponding to each target pixel point to obtain a polar coordinate value corresponding to each target pixel point, the direction of the water flow of the target river surface is determined based on the polar coordinate value of each target pixel point, and the flow rate of the target river surface is calculated according to the flow direction of the water flow of the target river surface, the space-time image of the search line and real distance information corresponding to each pixel point in the search line. According to the method provided by the application, the autocorrelation function can be obtained by carrying out Fourier transform on the space-time image, the inclination of the inclined stripes in the space-time image can be calculated based on the autocorrelation function, the inclination of the inclined stripes in the space-time image can be used for representing the direction of water flow, the accurate calculation of the water flow direction is realized, and the river surface flow rate can be accurately calculated based on the water flow direction.
As an optional embodiment of the present application, after step 107, the method further comprises: and determining the flow value in the preset calculation interval according to the surface flow rate of the target river and the area of the preset calculation interval of the target river.
The preset calculation interval may be an interval determined based on actual requirements, and the specific content of the preset calculation interval is not limited in the embodiment of the present application, and may be determined by a person skilled in the art according to requirements. In the embodiment of the application, the flow value of the preset calculation interval in the target river can be calculated based on the flow velocity area method, and the specific calculation process can be shown as the following formula (5):
wherein eta represents the river surface flow velocity coefficient, V i Represents the surface flow velocity of a preset calculation interval, A i Representing the area of the preset calculation interval.
As an alternative embodiment of the present application, step S101 specifically includes:
and b1, acquiring video data of a preset position in the target river. For example, the video data of the preset position in the target river may be video data acquired by a preset camera.
And b2, determining a preset search line based on the video data. For example, the preset search line may be a straight line set along the river flow direction in the video of the target river acquired in advance.
And b3, determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line. For example, the gradation information corresponding to the plurality of sampling times of the preset search line in the target river may be gradation information of the preset search line in the multi-frame image data in the video data.
As an alternative embodiment of the application, the two-dimensional autocorrelation function is obtained by:
wherein x represents the abscissa of the pixel in the spatiotemporal image, t represents the ordinate of the pixel in the spatiotemporal image, f (x, t) represents the gray value of the pixel in the spatiotemporal image, (τ) x ,τ t ) Offset parameter representing pixel point in spatio-temporal image, R (τ x ,τ t 0 is a two-dimensional autocorrelation function.
The embodiment of the application also discloses a river surface flow rate determining device, as shown in fig. 4, which comprises: the obtaining module 201 is configured to obtain gray information corresponding to a plurality of sampling times of a preset search line in a target river, and specifically refer to the description corresponding to step S101, which is not described herein again.
The generating module 202 is configured to generate a spatiotemporal image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, where the spatiotemporal image is used to represent an association relationship between a gray value of each pixel point on the search line and the sampling time and the length of the search line, and specifically refer to the description corresponding to step S102 above, which is not repeated herein.
The first determining module 203 is configured to perform fourier transform on the spatio-temporal image of the search line to obtain a two-dimensional autocorrelation function corresponding to the spatio-temporal image, where the two-dimensional autocorrelation function of the spatio-temporal image is used to characterize a correlation between a gray value of each pixel point in the spatio-temporal image and gray values of other pixel points, and specifically refer to the description corresponding to step S103, which is not repeated herein.
The second determining module 204 is configured to determine coordinate values corresponding to a plurality of target pixel points in the spatio-temporal image, where the correlation value is greater than the preset value, based on the two-dimensional autocorrelation function, and specifically refer to the description corresponding to step S104, which is not repeated herein.
The coordinate conversion module 205 is configured to convert coordinates of the coordinate values corresponding to each target pixel point to obtain polar coordinate values of each target pixel point, and detailed descriptions of the coordinate conversion module corresponding to the step S105 are omitted herein.
The third determining module 206 is configured to determine the water flow direction of the surface of the target river based on the polar coordinate value of each target pixel, and detailed description of the step S106 is omitted here.
The first calculating module 207 is configured to calculate the target river surface flow rate according to the target river surface water flow direction, the spatio-temporal image of the search line, and the real distance information corresponding to each pixel point in the search line, and specifically refer to the description corresponding to the above step S107, which is not repeated herein.
According to the river surface flow rate determining device, a space-time image of a preset search line in a target river is generated, fourier transformation is carried out on the space-time image to obtain a two-dimensional autocorrelation function of the space-time image, coordinate values corresponding to a plurality of target pixel points with correlation values larger than the preset value in the space-time image are determined based on the two-dimensional autocorrelation function, coordinate conversion is carried out on the coordinate values corresponding to each target pixel point to obtain a polar coordinate value corresponding to each target pixel point, the direction of the water flow of the target river surface is determined based on the polar coordinate value of each target pixel point, and the flow rate of the target river surface is calculated according to the flow direction of the water flow of the target river surface, the space-time image of the search line and real distance information corresponding to each pixel point in the search line. According to the method provided by the application, the autocorrelation function can be obtained by carrying out Fourier transform on the space-time image, the inclination of the inclined stripes in the space-time image can be calculated based on the autocorrelation function, the inclination of the inclined stripes in the space-time image can be used for representing the direction of water flow, the accurate calculation of the water flow direction is realized, and the river surface flow rate can be accurately calculated based on the water flow direction.
As an alternative embodiment of the present application, the apparatus further comprises: and the second calculation module is used for determining the flow value in the preset calculation interval according to the surface flow rate of the target river and the area of the preset calculation interval of the target river.
As an optional embodiment of the present application, the obtaining module includes: the acquisition sub-module is used for acquiring video data of a preset position in the target river; the first determining submodule is used for determining a preset search line based on video data; and the second determining submodule is used for determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line.
As an optional embodiment of the present application, the third determining module includes: a third determining submodule, configured to determine a stripe gradient in the spatio-temporal image based on polar coordinate values of each pixel point of the target area; determining the water flow direction on the search line based on the stripe gradient in the space-time image; and a fourth determining sub-module for determining a target river surface water flow direction based on the water flow direction on the search line.
As an alternative embodiment of the application, the two-dimensional autocorrelation function is obtained by:
wherein x represents the abscissa of the pixel in the spatiotemporal image, t represents the ordinate of the pixel in the spatiotemporal image, f (x, t) represents the gray value of the pixel in the spatiotemporal image, (τ) x ,τ t ) Offset parameter representing pixel point in spatio-temporal image, R (τ x ,τ t ) Is a two-dimensional autocorrelation function.
The embodiment of the present application further provides an electronic device, as shown in fig. 5, where the electronic device may include a processor 401 and a memory 402, where the processor 401 and the memory 402 may be connected by a bus or other means, and in fig. 5, the connection is exemplified by a bus.
The processor 401 may be a central processing unit (Central Processing Unit, CPU). The processor 401 may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or combinations thereof.
The memory 402 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules corresponding to the river surface flow rate determination method in the embodiment of the application. The processor 401 executes various functional applications of the processor and data processing, i.e., implements the river surface flow rate determination method in the above-described method embodiments, by running non-transitory software programs, instructions, and modules stored in the memory 402.
Memory 402 may include a storage program area that may store an operating system, at least one application program required for functionality, and a storage data area; the storage data area may store data created by the processor 401, or the like. In addition, memory 402 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, memory 402 may optionally include memory located remotely from processor 401, such remote memory being connectable to processor 401 through a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 402, which when executed by the processor 401, performs the river surface flow rate determination method in the embodiment shown in fig. 1.
The specific details of the electronic device may be understood correspondingly with respect to the corresponding related descriptions and effects in the embodiment shown in fig. 1, which are not repeated herein.
It will be appreciated by those skilled in the art that implementing all or part of the above-described embodiment method may be implemented by a computer program to instruct related hardware, where the program may be stored in a computer readable storage medium, and the program may include the above-described embodiment method when executed. Wherein the storage medium may be a magnetic Disk, an optical Disk, a Read-Only Memory (ROM), a random access Memory (RandomAccessMemory, RAM), a Flash Memory (Flash Memory), a Hard Disk (HDD), a Solid State Drive (SSD), or the like; the storage medium may also comprise a combination of memories of the kind described above.
Although embodiments of the present application have been described in connection with the accompanying drawings, various modifications and variations may be made by those skilled in the art without departing from the spirit and scope of the application, and such modifications and variations are within the scope of the application as defined by the appended claims.
Claims (10)
1. A river surface flow rate determination method, comprising:
acquiring gray information corresponding to a plurality of sampling times of a preset search line in a target river;
generating a space-time image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, wherein the space-time image is used for representing the association relationship between gray values of each pixel point on the search line, the sampling time and the length of the search line;
performing Fourier transform on the space-time images of the search lines to obtain a two-dimensional autocorrelation function corresponding to the space-time images, wherein the two-dimensional autocorrelation function of the space-time images is used for representing the correlation between the gray value of each pixel point in the space-time images and the gray values of other pixel points;
determining coordinate values corresponding to a plurality of target pixel points with correlation values larger than a preset value in the space-time image based on the two-dimensional autocorrelation function;
coordinate conversion is carried out on the coordinate value corresponding to each target pixel point, and the polar coordinate value of each target pixel point is obtained;
determining the water flow direction of the surface of the target river based on the polar coordinate value of each target pixel point;
and calculating the target river surface flow rate according to the flow direction of the water flow on the target river surface, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line.
2. The method of claim 1, wherein after calculating the target river surface flow rate from the target river surface flow direction, the spatiotemporal image of the search line, and the true distance information for each pixel in the search line, the method further comprises:
and determining the flow value in the preset calculation interval according to the surface flow rate of the target river and the area of the preset calculation interval of the target river.
3. The method of claim 1, wherein the acquiring gray information corresponding to a plurality of sampling times of a preset search line in the target river comprises:
acquiring video data of a preset position in a target river;
determining a preset search line based on the video data;
and determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line.
4. The method of claim 1, wherein determining a target river surface water flow direction based on the polar coordinate value of each pixel of the target area comprises:
determining the gradient of stripes in the space-time image based on the polar coordinate value of each pixel point of the target area;
determining a water flow direction on the search line based on the fringe inclination in the spatiotemporal image;
the target river surface water flow direction is determined based on the water flow direction on the search line.
5. The method of claim 1, wherein the two-dimensional autocorrelation function is obtained by:
wherein x represents the abscissa of the pixel in the spatiotemporal image, t represents the ordinate of the pixel in the spatiotemporal image, f (x, t) represents the gray value of the pixel in the spatiotemporal image, (τ) x ,τ t ) Offset parameter representing pixel point in spatio-temporal image, R (τ x ,τ t ) Is a two-dimensional autocorrelation function.
6. A river surface flow rate determination apparatus, comprising:
the acquisition module is used for acquiring gray information corresponding to a plurality of sampling times of a preset search line in a target river;
the generation module is used for generating a space-time image of the search line based on gray information corresponding to a plurality of sampling times of the preset search line, wherein the space-time image is used for representing the association relation between the gray value of each pixel point on the search line, the sampling time and the length of the search line;
the first determining module is used for carrying out Fourier transformation on the space-time image of the search line to obtain a two-dimensional autocorrelation function corresponding to the space-time image, and the two-dimensional autocorrelation function of the space-time image is used for representing the correlation between the gray value of each pixel point in the space-time image and the gray values of other pixel points;
the second determining module is used for determining coordinate values corresponding to a plurality of target pixel points with correlation values larger than a preset value in the space-time image based on the two-dimensional autocorrelation function;
the coordinate conversion module is used for carrying out coordinate conversion on the coordinate value corresponding to each target pixel point to obtain the polar coordinate value of each target pixel point;
the third determining module is used for determining the water flow direction of the surface of the target river based on the polar coordinate value of each target pixel point;
the first calculation module is used for calculating the target river surface flow rate according to the flow direction of the target river surface water flow, the space-time image of the search line and the real distance information corresponding to each pixel point in the search line.
7. The apparatus of claim 6, wherein the apparatus further comprises:
and the second calculation module is used for determining the flow value in the preset calculation interval according to the target river surface flow rate and the preset calculation interval area of the target river.
8. The apparatus of claim 6, wherein the acquisition module comprises:
the acquisition sub-module is used for acquiring video data of a preset position in the target river;
the first determining submodule is used for determining a preset search line based on the video data;
and the second determining submodule is used for determining gray information corresponding to a plurality of sampling times of the preset search line in the target river based on the video data and the preset search line.
9. An electronic device, comprising: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to cause the at least one processor to perform the river surface flow rate determination method of any one of claims 1-5.
10. A computer readable storage medium having stored thereon a computer program, which when executed by a processor implements the river surface flow rate determination method according to any one of claims 1-5.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310631562.5A CN116679080B (en) | 2023-05-30 | 2023-05-30 | River surface flow velocity determining method and device and electronic equipment |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310631562.5A CN116679080B (en) | 2023-05-30 | 2023-05-30 | River surface flow velocity determining method and device and electronic equipment |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN116679080A true CN116679080A (en) | 2023-09-01 |
| CN116679080B CN116679080B (en) | 2024-10-01 |
Family
ID=87784779
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202310631562.5A Active CN116679080B (en) | 2023-05-30 | 2023-05-30 | River surface flow velocity determining method and device and electronic equipment |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN116679080B (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN117452021A (en) * | 2023-10-08 | 2024-01-26 | 中国农业大学 | Two-dimensional space-time image velocity measurement method and device for field river surface and storage medium |
Citations (22)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH08212342A (en) * | 1995-02-02 | 1996-08-20 | Victor Co Of Japan Ltd | Method for extracting texture area of image |
| JPH10289319A (en) * | 1997-04-16 | 1998-10-27 | Sumitomo Electric Ind Ltd | Inspection method and inspection device for streak defects |
| JP2011081761A (en) * | 2009-09-11 | 2011-04-21 | Toyama Univ | Method, apparatus and program for estimation of motion |
| KR20120022533A (en) * | 2010-09-01 | 2012-03-12 | 한국전자통신연구원 | Method and apparatus for image processing based on multiple texture image |
| WO2013100785A1 (en) * | 2011-12-29 | 2013-07-04 | Intel Corporation | Method of and apparatus for low-complexity detection of periodic textures |
| CN103996171A (en) * | 2014-05-05 | 2014-08-20 | 河海大学 | Fluid motion vector estimation method based on space-time image |
| US20150116353A1 (en) * | 2013-10-30 | 2015-04-30 | Morpho, Inc. | Image processing device, image processing method and recording medium |
| CN104777327A (en) * | 2015-03-17 | 2015-07-15 | 河海大学 | Time-space image speed measuring system and method based on auxiliary laser calibration |
| CN106841673A (en) * | 2017-01-16 | 2017-06-13 | 甘肃农业大学 | Device and method for measuring average flow velocity on river surface |
| US20190005658A1 (en) * | 2017-06-30 | 2019-01-03 | The Government Of The Us, As Represented By The Secretary Of The Navy | Autonomous characterization of water flow from surface water velocity |
| CN110675371A (en) * | 2019-09-05 | 2020-01-10 | 北京达佳互联信息技术有限公司 | Scene switching detection method and device, electronic equipment and storage medium |
| US20200357112A1 (en) * | 2019-05-08 | 2020-11-12 | Kabushiki Kaisha Toshiba | Determination device, determination system, welding system, determination method, and storage medium |
| CN113012195A (en) * | 2021-03-04 | 2021-06-22 | 西安电子科技大学 | Method for estimating river surface flow velocity based on optical flow calculation and readable storage medium |
| CN113077488A (en) * | 2021-04-02 | 2021-07-06 | 昆明理工大学 | River surface flow velocity detection method and device |
| CN113222976A (en) * | 2021-05-31 | 2021-08-06 | 河海大学 | Space-time image texture direction detection method and system based on DCNN and transfer learning |
| US20220083004A1 (en) * | 2019-06-28 | 2022-03-17 | Fujifilm Corporation | Image processing apparatus, evaluation system, image processing program, and image processing method |
| CN115035445A (en) * | 2022-06-06 | 2022-09-09 | 广州伏羲智能科技有限公司 | Floater detection method and system based on background pixel value difference algorithm |
| CN115131373A (en) * | 2022-07-14 | 2022-09-30 | 西安电子科技大学 | SAR image segmentation method based on texture features and SLIC |
| CN115359028A (en) * | 2022-08-31 | 2022-11-18 | 深圳市人工智能与机器人研究院 | Liquid flow velocity detection method, detection device and storage medium |
| CN115456916A (en) * | 2022-11-11 | 2022-12-09 | 武汉大水云科技有限公司 | Surface flow velocity calculation method based on image quality |
| CN115908370A (en) * | 2022-12-13 | 2023-04-04 | 山东沂蒙抽水蓄能有限公司 | A Method of Realizing Water Level Detection Based on Image Inverse Perspective Transformation |
| CN115953550A (en) * | 2022-12-21 | 2023-04-11 | 江汉大学 | Point cloud outlier removal system and method for line structured light scanning |
-
2023
- 2023-05-30 CN CN202310631562.5A patent/CN116679080B/en active Active
Patent Citations (22)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH08212342A (en) * | 1995-02-02 | 1996-08-20 | Victor Co Of Japan Ltd | Method for extracting texture area of image |
| JPH10289319A (en) * | 1997-04-16 | 1998-10-27 | Sumitomo Electric Ind Ltd | Inspection method and inspection device for streak defects |
| JP2011081761A (en) * | 2009-09-11 | 2011-04-21 | Toyama Univ | Method, apparatus and program for estimation of motion |
| KR20120022533A (en) * | 2010-09-01 | 2012-03-12 | 한국전자통신연구원 | Method and apparatus for image processing based on multiple texture image |
| WO2013100785A1 (en) * | 2011-12-29 | 2013-07-04 | Intel Corporation | Method of and apparatus for low-complexity detection of periodic textures |
| US20150116353A1 (en) * | 2013-10-30 | 2015-04-30 | Morpho, Inc. | Image processing device, image processing method and recording medium |
| CN103996171A (en) * | 2014-05-05 | 2014-08-20 | 河海大学 | Fluid motion vector estimation method based on space-time image |
| CN104777327A (en) * | 2015-03-17 | 2015-07-15 | 河海大学 | Time-space image speed measuring system and method based on auxiliary laser calibration |
| CN106841673A (en) * | 2017-01-16 | 2017-06-13 | 甘肃农业大学 | Device and method for measuring average flow velocity on river surface |
| US20190005658A1 (en) * | 2017-06-30 | 2019-01-03 | The Government Of The Us, As Represented By The Secretary Of The Navy | Autonomous characterization of water flow from surface water velocity |
| US20200357112A1 (en) * | 2019-05-08 | 2020-11-12 | Kabushiki Kaisha Toshiba | Determination device, determination system, welding system, determination method, and storage medium |
| US20220083004A1 (en) * | 2019-06-28 | 2022-03-17 | Fujifilm Corporation | Image processing apparatus, evaluation system, image processing program, and image processing method |
| CN110675371A (en) * | 2019-09-05 | 2020-01-10 | 北京达佳互联信息技术有限公司 | Scene switching detection method and device, electronic equipment and storage medium |
| CN113012195A (en) * | 2021-03-04 | 2021-06-22 | 西安电子科技大学 | Method for estimating river surface flow velocity based on optical flow calculation and readable storage medium |
| CN113077488A (en) * | 2021-04-02 | 2021-07-06 | 昆明理工大学 | River surface flow velocity detection method and device |
| CN113222976A (en) * | 2021-05-31 | 2021-08-06 | 河海大学 | Space-time image texture direction detection method and system based on DCNN and transfer learning |
| CN115035445A (en) * | 2022-06-06 | 2022-09-09 | 广州伏羲智能科技有限公司 | Floater detection method and system based on background pixel value difference algorithm |
| CN115131373A (en) * | 2022-07-14 | 2022-09-30 | 西安电子科技大学 | SAR image segmentation method based on texture features and SLIC |
| CN115359028A (en) * | 2022-08-31 | 2022-11-18 | 深圳市人工智能与机器人研究院 | Liquid flow velocity detection method, detection device and storage medium |
| CN115456916A (en) * | 2022-11-11 | 2022-12-09 | 武汉大水云科技有限公司 | Surface flow velocity calculation method based on image quality |
| CN115908370A (en) * | 2022-12-13 | 2023-04-04 | 山东沂蒙抽水蓄能有限公司 | A Method of Realizing Water Level Detection Based on Image Inverse Perspective Transformation |
| CN115953550A (en) * | 2022-12-21 | 2023-04-11 | 江汉大学 | Point cloud outlier removal system and method for line structured light scanning |
Non-Patent Citations (7)
| Title |
|---|
| FUJITA, I: "Efficient and accurate estimation of water surface velocity in STIV", 《ENVIRONMENTAL FLUID MECHANICS》, vol. 19, no. 5, 28 November 2019 (2019-11-28), pages 1363 - 1378, XP036939500, DOI: 10.1007/s10652-018-9651-3 * |
| PHILIPPE, P: "Gravitational Instability of a Granular Medium Subjected to an Inner Water Flow", 《 POWDERS AND GRAINS 2009》, vol. 1145, 17 July 2009 (2009-07-17), pages 959 - 962 * |
| 张保民: "《成像系统分析导论》", vol. 1, 31 August 1992, 国防工业出版社, pages: 108 * |
| 张尚弘 等: "基于纹理的流场动态可视化平台开发", 《水力发电学报》, vol. 30, no. 5, 31 October 2011 (2011-10-31), pages 119 - 124 * |
| 张振 等: "图像法测流系统在山区河流监测中的应用", 《中国水利学会》, 19 July 2021 (2021-07-19), pages 289 - 301 * |
| 张振 等: "图像法测流系统在山区河流监测中的应用", 《中国水利学会2018学术年会》, 19 July 2021 (2021-07-19), pages 289 - 301 * |
| 王慧斌 等: "基于时空图像频谱的时均流场重建方法", 《仪器仪表学报》, vol. 36, no. 3, 31 March 2015 (2015-03-31), pages 623 - 630 * |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN117452021A (en) * | 2023-10-08 | 2024-01-26 | 中国农业大学 | Two-dimensional space-time image velocity measurement method and device for field river surface and storage medium |
Also Published As
| Publication number | Publication date |
|---|---|
| CN116679080B (en) | 2024-10-01 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| KR101996992B1 (en) | Apparatus and Method for Measuring Flow Velocity of River using Optical Flow Image Processing | |
| CN110473260B (en) | Wave video measuring device and method | |
| US12320687B2 (en) | Systems and methods for remote sensing of river velocity using video and an optical flow algorithm | |
| CN111798386B (en) | River channel flow velocity measurement method based on edge identification and maximum sequence density estimation | |
| CN103996171B (en) | Fluid motion vector estimation method based on space-time image | |
| Benetazzo et al. | Stereo wave imaging from moving vessels: Practical use and applications | |
| CN104297516B (en) | A kind of two-dimentional velocity field mearsurement method of flow surface | |
| CN104215795A (en) | Large scale particle picture velocimetry based on Haokong surface flow field computational algorithm | |
| CN115471777A (en) | Refined water flow velocity field acquisition method and system based on video identification | |
| CN116342656A (en) | A spatio-temporal image velocity measurement method and device based on adaptive edge detection | |
| CN104777327A (en) | Time-space image speed measuring system and method based on auxiliary laser calibration | |
| Do et al. | A simple camera calibration method for vehicle velocity estimation | |
| CN103438826A (en) | Three-dimensional measurement system and three-dimensional measurement method for steel plate with lasers and vision combined | |
| CN115143056B (en) | Method and device for measuring shutdown attitude parameters of wind driven generator | |
| JP4574657B2 (en) | Method and apparatus for measuring water flow | |
| CN116679080B (en) | River surface flow velocity determining method and device and electronic equipment | |
| CN105607062B (en) | A kind of weather radar figure analysis system | |
| CN115824170A (en) | A Method of Fusion of Photogrammetry and LiDAR to Measure Ocean Waves | |
| Ai et al. | The optimal scale level of complex steerable pyramid for phase-based motion estimation under different motion ranges and target sizes | |
| CN114594467B (en) | A method, device, electronic device and storage medium for determining heading angle | |
| CN108122244B (en) | Video speed measuring method and device for video image | |
| Sirenden et al. | Algorithm comparisons among space time volume velocimetry, horn-schunk, and lucas-kanade for the analysis of water surface velocity image sequences | |
| Colvin et al. | Extracting nearshore wave properties from video: A new method for coastal estuaries | |
| CN115932884B (en) | Wave direction spectrum measurement method and system based on three-dimensional laser radar | |
| CN119048546A (en) | Non-contact flow measurement method based on frame difference and space-time image velocity measurement and computer device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |