CN116385735B - Water level measurement method based on image recognition - Google Patents

Water level measurement method based on image recognition Download PDF

Info

Publication number
CN116385735B
CN116385735B CN202310636856.7A CN202310636856A CN116385735B CN 116385735 B CN116385735 B CN 116385735B CN 202310636856 A CN202310636856 A CN 202310636856A CN 116385735 B CN116385735 B CN 116385735B
Authority
CN
China
Prior art keywords
data
water gauge
image
processing
generate
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.)
Active
Application number
CN202310636856.7A
Other languages
Chinese (zh)
Other versions
CN116385735A (en
Inventor
陈伟昌
赵帅
杨跃
张兵
张彬培
洪晓达
乐鸣
韦三刚
赵旭升
赖杭
田茂春
徐奕蒙
王高丹
张水平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Pearl River Hydraulic Research Institute of PRWRC
Original Assignee
Pearl River Hydraulic Research Institute of PRWRC
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Pearl River Hydraulic Research Institute of PRWRC filed Critical Pearl River Hydraulic Research Institute of PRWRC
Priority to CN202310636856.7A priority Critical patent/CN116385735B/en
Publication of CN116385735A publication Critical patent/CN116385735A/en
Application granted granted Critical
Publication of CN116385735B publication Critical patent/CN116385735B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/44Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01FMEASURING VOLUME, VOLUME FLOW, MASS FLOW OR LIQUID LEVEL; METERING BY VOLUME
    • G01F23/00Indicating or measuring liquid level or level of fluent solid material, e.g. indicating in terms of volume or indicating by means of an alarm
    • G01F23/04Indicating or measuring liquid level or level of fluent solid material, e.g. indicating in terms of volume or indicating by means of an alarm by dip members, e.g. dip-sticks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • G06F30/27Design optimisation, verification or simulation using machine learning, e.g. artificial intelligence, neural networks, support vector machines [SVM] or training a model
    • G06T5/70
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/155Segmentation; Edge detection involving morphological operators
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/187Segmentation; Edge detection involving region growing; involving region merging; involving connected component labelling
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/26Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/774Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/776Validation; Performance evaluation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V2201/00Indexing scheme relating to image or video recognition or understanding
    • G06V2201/02Recognising information on displays, dials, clocks
    • YGENERAL 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
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A90/00Technologies having an indirect contribution to adaptation to climate change
    • Y02A90/30Assessment of water resources

Abstract

The invention relates to the technical field of machine vision, and particularly discloses a water level measurement method based on image recognition, which comprises the following steps of: the automatic camera is utilized to perform automatic water gauge image acquisition processing on the water gauge, and automatic water gauge acquisition data are generated; generating water gauge distributed cloud data by utilizing media cloud distribution processing based on automatic water gauge acquisition data; based on the water gauge distributed cloud data, performing morphological contour detection segmentation processing on the water gauge to generate water gauge standardized region image data; performing model construction training treatment on the initial scale data by using a neural network algorithm to generate a water gauge scaling recognition model; model training processing is carried out on the water gauge scales by utilizing resolution self-adaptive scale calibration calculation, and water level perception data is generated. According to the method, the effective information containing the water gauge image information is acquired through the standard image acquisition flow and is uploaded to the cloud, standard source image data and a large amount of training are standardized, and a stable training model and parameters are obtained.

Description

Water level measurement method based on image recognition
Technical Field
The invention relates to the technical field of machine vision, in particular to a water level measurement method based on image recognition.
Background
The water level refers to the elevation of the free water surface relative to a certain basal plane, and the change of the water level is mainly caused by the increase and decrease of the water quantity of the water body, so that the water level is the most intuitive factor for reflecting the water condition of the water body. People often set a water level safety warning value for reservoirs, lakes and rivers, and when the real-time water level is higher than the water level safety warning value, the occurrence of disasters such as flood, dam break and the like can be predicted. Therefore, the water level monitoring has important significance for various disaster defenses in water conservancy. Currently, a water gauge is still an important tool for measuring water level, and people can intuitively acquire the water level value through on-site observation. In the period of water conservancy informatization, people can remotely and rapidly acquire water gauge images of a water conservancy site by adopting an image remote sensing technology, and the water level value is obtained by inquiring and turning over the images in real time through a visual system. Then, the above means for acquiring the water level all rely on a large number of manual operations, resulting in low working efficiency. Along with the increasing maturity and popularization of artificial intelligence technology, traditional image recognition technology can be combined with the technology, water level recognition can be rapidly and accurately realized under the interference of water gauge reflection exists, water gauges have sludge and water gauge partial areas are shielded by weeds, when water level measurement is carried out in the traditional technology, the image acquisition method containing the water gauges is not standard, the quality of acquired source images is not high, the image processing method is not standard, the processing result is greatly influenced by the processing flow, meanwhile, a training model is not uniform, the source is not opened, and parameter setting is required to be manually modified according to the quality of the source image data.
Nowadays, the blockchain technology is increasingly widely applied, plays a great role in water level measurement, is an advanced decentralization and distributed database technology, and has the core function of building and maintaining a tamper-proof digital ledger. All transaction records in the block chain are stored in a data block and are linked into a chain consisting of blocks, and each block contains the hash values of all the previous blocks, so that transparency and non-tamper resistance of all data are ensured, and the integrity and source of the data cannot be effectively verified and guaranteed by the traditional technology, so that the data are easy to tamper.
Disclosure of Invention
Based on this, it is necessary to provide a water level measuring method based on image recognition to solve at least one of the above technical problems.
In order to achieve the above object, the present invention provides a water level measurement method based on image recognition, the method comprising the steps of:
step S1: the automatic camera is utilized to perform automatic water gauge image acquisition processing on the water gauge, and automatic water gauge acquisition data are generated;
step S2: generating water gauge distributed cloud data by utilizing media cloud distribution processing based on automatic water gauge acquisition data;
Step S3: based on cloud image data, performing morphological contour detection segmentation processing on the water gauge to generate water gauge standardized region image data;
step S4: based on the standardized region image data of the water gauge, performing image linear fitting verification processing on the water gauge by using a blockchain technology to generate initial scale data;
step S5: performing model construction training treatment on the initial scale data by using a neural network algorithm to generate a water gauge scaling recognition model;
step S6: and performing model training treatment on the water gauge calibration recognition model by utilizing resolution self-adaptive scale calibration calculation to generate water level perception data.
The invention captures images through an automatic camera and performs image calibration on the images to generate raw water gauge image data, performs enhanced denoising processing and segmentation positioning processing on the raw water gauge image data to generate calibrated segmentation water gauge image data, performs verification correction processing and automatic feedback control processing on the segmentation water gauge image data to generate automatic water gauge acquisition data, improves the definition and quality of the water gauge image, realizes automatic water gauge image recognition segmentation, further improves the accuracy of water gauge reading, reduces data errors, improves the accuracy and stability of the water gauge image data, generates corrected water gauge image data which can be used for measurement, performs dual-flow multipath adaptive transmission processing on the automatic water gauge acquisition data, generates water gauge pre-optimized transmission data, optimizes data transmission, improves transmission efficiency, reduces the risk of data loss, performs scheduling distribution on water gauge routing optimization by utilizing multichannel dynamic scheduling processing to generate water gauge multichannel processing data, realizes efficient utilization of network resources, reduces network congestion, improves the performance of an overall system, performs real-time depth analysis processing on the water gauge multichannel processing data to generate water gauge parameter image data, improves the data processing speed and the accuracy, facilitates the data distribution type monitoring and the accuracy of the water gauge image data, reduces the data, and the data to be distributed, ensures the reliability of the water gauge data to be distributed and the area-region-based on the data, and the data is stable, and the data is stored and the area-region-based on the data is safe and the data is stored and the data-distributed and is safe, generating water gauge region topological structure data, enhancing image definition, being capable of more clearly identifying a water gauge region, calculating the water gauge region by utilizing a two-dimensional matrix region coordinate summation formula, improving accuracy of analysis results, carrying out standardized processing on the water gauge two-dimensional image data, generating water gauge standardized region image data so as to facilitate subsequent analysis and application, carrying out linear fitting and scale extraction on the water gauge standardized region image data, generating piecewise scale detection data, improving scale accuracy and precision, carrying out data verification by utilizing a block chain technology, ensuring data safety and reliability, further improving water gauge detection accuracy and precision, processing initial scale data by utilizing an adaptive image definition extraction strategy, generating adaptive definition image data, improving accuracy of subsequent processing, carrying out image layer definition comparison processing based on the adaptive definition image data, generating low resolution fuzzy layer data, helping to identify images with different resolutions, improving image processing effect, constructing a training model according to the low resolution fuzzy layer data and generating a calibration identification training set by using a residual network structure neural network algorithm, generating a water gauge calibration identification model by using residual network water gauge calibration processing identification calibration training set, accurately identifying a water gauge, realizing automatic and intelligent water gauge calibration, performing water level area image preprocessing on segmented linear fitting image data, generating water level image preprocessing data, further improving image quality, facilitating subsequent analysis application, generating inverted image adaptive water level output data by using water level inverted image automatic compatible processing on the water level image preprocessing data, and adaptively outputting the water level data under a complex environment, the normal operation of the model is guaranteed, the end-to-end training prediction recognition processing of the residual network is carried out on the reflection adaptive water level output data, water level sensing data are generated, a stable training model and parameters are obtained, the water level efficiency is obviously reduced due to the influence of external nonresistance factors, a stable training model and parameters are obtained, and the water level efficiency is obviously reduced due to the influence of external nonresistance factors.
Drawings
FIG. 1 is a schematic flow chart of a water level measurement method based on image recognition according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of an automated water gauge image acquisition process for a water gauge according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of generating water gauge distributed cloud data by media cloud distribution according to an embodiment of the present invention;
FIG. 4 is a flowchart illustrating a morphological contour detection segmentation process according to an embodiment of the present invention;
FIG. 5 is a schematic flow chart of a linear image fitting verification process for a water gauge using a blockchain technique according to an embodiment of the present invention;
FIG. 6 is a schematic flow chart of a model building training process according to an embodiment of the present invention;
FIG. 7 is a flow chart of a calibration calculation using resolution adaptive calibration according to an embodiment of the present invention;
the achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
The following is a clear and complete description of the technical method of the present patent in conjunction with the accompanying drawings, and it is evident that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, are intended to fall within the scope of the present invention.
Furthermore, the drawings are merely schematic illustrations of the present application and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus a repetitive description thereof will be omitted. Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities. The functional entities may be implemented in software or in one or more hardware modules or integrated circuits or in different networks and/or processor methods and/or microcontroller methods.
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the application.
In order to achieve the above objective, referring to fig. 1 to 7, an embodiment of the present application provides a water level measurement method based on image recognition, which includes the following steps:
step S1: the automatic camera is utilized to perform automatic water gauge image acquisition processing on the water gauge, and automatic water gauge acquisition data are generated;
step S2: generating water gauge distributed cloud data by utilizing media cloud distribution processing based on automatic water gauge acquisition data;
step S3: based on the water gauge distributed cloud data, performing morphological contour detection segmentation processing on the water gauge to generate water gauge standardized region image data;
Step S4: based on the standardized region image data of the water gauge, performing image linear fitting verification processing on the water gauge by using a blockchain technology to generate initial scale data;
step S5: performing model construction training treatment on the initial scale data by using a neural network algorithm to generate a water gauge scaling recognition model;
step S6: and performing model training treatment on the water gauge calibration recognition model by utilizing resolution self-adaptive scale calibration calculation to generate water level perception data.
The invention captures images through an automatic camera and performs image calibration on the images to generate raw water gauge image data, performs enhanced denoising processing and segmentation positioning processing on the raw water gauge image data to generate calibrated segmentation water gauge image data, performs verification correction processing and automatic feedback control processing on the segmentation water gauge image data to generate automatic water gauge acquisition data, improves the definition and quality of the water gauge image, realizes automatic water gauge image recognition segmentation, further improves the accuracy of water gauge reading, reduces data errors, improves the accuracy and stability of the water gauge image data, generates corrected water gauge image data which can be used for measurement, performs dual-flow multipath adaptive transmission processing on the automatic water gauge acquisition data, generates water gauge pre-optimized transmission data, optimizes data transmission, improves transmission efficiency, reduces the risk of data loss, performs scheduling distribution on water gauge routing optimization by utilizing multichannel dynamic scheduling processing to generate water gauge multichannel processing data, realizes efficient utilization of network resources, reduces network congestion, improves the performance of an overall system, performs real-time depth analysis processing on the water gauge multichannel processing data to generate water gauge parameter image data, improves the data processing speed and the accuracy, facilitates the data distribution type monitoring and the accuracy of the water gauge image data, reduces the data, and the data to be distributed, ensures the reliability of the water gauge data to be distributed and the area-region-based on the data, and the data is stable, and the data is stored and the area-region-based on the data is safe and the data is stored and the data-distributed and is safe, generating water gauge region topological structure data, enhancing image definition, being capable of more clearly identifying a water gauge region, calculating the water gauge region by utilizing a two-dimensional matrix region coordinate summation formula, improving accuracy of analysis results, carrying out standardized processing on the water gauge two-dimensional image data, generating water gauge standardized region image data so as to facilitate subsequent analysis and application, carrying out linear fitting and scale extraction on the water gauge standardized region image data, generating piecewise scale detection data, improving scale accuracy and precision, carrying out data verification by utilizing a block chain technology, ensuring data safety and reliability, further improving water gauge detection accuracy and precision, processing initial scale data by utilizing an adaptive image definition extraction strategy, generating adaptive definition image data, improving accuracy of subsequent processing, carrying out image layer definition comparison processing based on the adaptive definition image data, generating low resolution fuzzy layer data, helping to identify images with different resolutions, improving image processing effect, constructing a training model according to the low resolution fuzzy layer data and generating a calibration identification training set by using a residual network structure neural network algorithm, generating a water gauge calibration identification model by using residual network water gauge calibration processing identification calibration training set, accurately identifying a water gauge, realizing automatic and intelligent water gauge calibration, performing water level area image preprocessing on segmented linear fitting image data, generating water level image preprocessing data, further improving image quality, facilitating subsequent analysis application, generating inverted image adaptive water level output data by using water level inverted image automatic compatible processing on the water level image preprocessing data, and adaptively outputting the water level data under a complex environment, the normal operation of the model is guaranteed, the end-to-end training prediction recognition processing of the residual network is carried out on the reflection adaptive water level output data, water level sensing data are generated, a stable training model and parameters are obtained, the water level efficiency is obviously reduced due to the influence of external nonresistance factors, a stable training model and parameters are obtained, and the water level efficiency is obviously reduced due to the influence of external nonresistance factors.
In the embodiment of the present invention, as described with reference to fig. 1, a schematic flow chart of steps of a water level measurement method based on image recognition according to the present invention is provided, and in this example, the water level measurement method based on image recognition includes the following steps:
step S1: the automatic camera is utilized to perform automatic water gauge image acquisition processing on the water gauge, and automatic water gauge acquisition data are generated;
in the embodiment of the invention, the automatic camera is triggered to acquire the image by placing the water gauge at the preset position, a plurality of acquisition points are arranged to ensure that the complete image is acquired, the acquired image is preprocessed, the image denoising, the image contrast enhancement and the like are performed, the characteristic extraction and the information extraction are performed on the preprocessed water gauge image, the data verification correction processing and the automatic feedback control optimization processing are performed, and the automatic water gauge acquisition data are generated.
Step S2: generating water gauge distributed cloud data by utilizing media cloud distribution processing based on automatic water gauge acquisition data;
according to the embodiment of the invention, the data is divided into two flows, the transmission rate of the data on different paths is automatically adjusted by utilizing a plurality of network paths, so that the water gauge route optimization data is generated, the data is distributed to the proper channels according to different broadband requirements and transmission rates based on the water gauge route optimization data, the dispatching distribution processing is performed, the water gauge multi-channel processing data is generated, the real-time deep analysis processing is performed on the water gauge multi-channel processing data to generate the water gauge parameter image data, and meanwhile, the data is subjected to the distributed high-reliability storage processing, so that the water gauge distributed cloud data is generated.
Step S3: based on cloud image data, performing morphological contour detection segmentation processing on the water gauge to generate water gauge standardized region image data;
in the embodiment of the invention, morphological contour detection and segmentation processing is performed on cloud image data, wherein the morphological contour detection and segmentation processing comprises binarization rotation correction processing, contour line distribution detection, morphological region segmentation processing, a two-dimensional matrix region coordinate summation formula and a gradient edge weighting scale formula, so that water gauge standardized region image data is generated.
Step S4: based on the standardized region image data of the water gauge, performing image linear fitting verification processing on the water gauge by using a blockchain technology to generate initial scale data;
the embodiment of the invention relates to a water gauge image data processing method, which comprises the steps of carrying out segmentation extraction line merging processing on water gauge standardized region image data to generate segmented linear fitting image data, carrying out transverse scale extraction processing on segmented linear fitting data to generate segmented scale detection data, carrying out data verification processing by using block chain segmented scale verification processing to generate block scale detection data, and carrying out dynamic logic relation detection processing on the block scale detection data to generate initial scale data, so that the accuracy and the continuity of the water gauge scale data are ensured.
Step S5: performing model construction training treatment on the initial scale data by using a neural network algorithm to generate a water gauge scaling recognition model;
the construction steps of the scale calibration and identification model of the water scale in the embodiment of the invention specifically comprise: processing the initial scale data by adopting an adaptive image definition extraction strategy to generate adaptive definition image data; performing layer definition comparison processing according to the self-adaptive definition image data to generate low-resolution fuzzy layer data; and constructing a neural network model of a residual network structure according to the low-resolution fuzzy layer data, generating a calibration recognition training set, and training the model to generate a water gauge calibration recognition model.
Step S6: and performing model training treatment on the water gauge calibration recognition model by utilizing resolution self-adaptive scale calibration calculation to generate water level perception data.
In the embodiment of the invention, the water level sensing system and the water level sensing method are provided, segmented linear fitting image data is obtained through a water gauge calibration recognition model, gaussian filtering is utilized to remove noise, water gauge calibration is recognized, scaling and stretching processing are carried out on an image, so that water level image preprocessing data are generated, whether water gauge reflection exists or not is judged through reflection detection, reflection processing is carried out if the water gauge reflection exists, reflection adaptive water level output data are generated, end-to-end training prediction recognition processing is carried out through a residual network, and water level sensing data are generated.
Preferably, step S1 comprises the steps of:
step S11: performing image calibration pretreatment on the water gauge environment image by using an automatic camera to generate original water gauge image data;
step S12: performing image enhancement denoising processing based on the raw water scale image data to generate denoising water scale image data;
step S13: dividing and positioning the denoising water gauge image data by using a digital water gauge image recognition method to generate calibrated divided water gauge image data;
step S14: performing data verification and correction processing on the calibrated and divided water gauge image data to generate corrected water gauge image data;
step S15: and (3) carrying out automatic feedback control optimization processing on the corrected water gauge image data to generate automatic water gauge acquisition data.
As an example of the present invention, referring to fig. 2, a detailed implementation step flow diagram of step S1 in fig. 1 is shown, where step S1 includes:
step S11: performing image calibration pretreatment on the water gauge environment image by using an automatic camera to generate original water gauge image data;
in the embodiment of the invention, the automatic camera equipment is utilized to shoot the water gauge environment image, the image is subjected to average processing by utilizing a multi-frame average method according to the illumination condition of the water gauge environment, the shot water gauge image is subjected to pretreatment, and the radial distortion and tangential distortion in the image are corrected. And carrying out flat field correction on the image, eliminating uneven illumination in the image, and improving the dynamic range of the image so as to generate original water gauge image data.
Step S12: performing image enhancement denoising processing based on the raw water scale image data to generate denoising water scale image data;
in the embodiment of the invention, the image data of the raw water ruler is subjected to image enhancement processing, including contrast stretching and brightness adjustment operation, and is subjected to denoising processing by adopting a median filtering denoising algorithm, so that image noise is eliminated, and the denoising water ruler image data is generated.
Step S13: dividing and positioning the denoising water gauge image data by using a digital water gauge image recognition method to generate calibrated divided water gauge image data;
in the embodiment of the invention, the edge detection and contour extraction digital image recognition method is adopted to segment and position the denoising water gauge image data, the water gauge is distinguished from the background through an image segmentation algorithm, the scale on the water gauge is positioned, and the number of the calibrated segmented water gauge images is generated after the processing.
Step S14: performing data verification and correction processing on the calibrated and divided water gauge image data to generate corrected water gauge image data;
and (3) performing scale positioning and calibration on the calibrated and segmented water gauge image data, comparing the actual measured value with the scale positions and the number in the image, determining the scale accuracy in the image, correcting according to the need, performing smoothing treatment on the calibrated and segmented water gauge image data by using a cubic spline interpolation and polynomial fitting method, eliminating abnormal data, and converting the calibrated water gauge image data into the actual scale values, thereby generating the corrected water gauge image data.
Step S15: and (3) carrying out automatic feedback control optimization processing on the corrected water gauge image data to generate automatic water gauge acquisition data.
In the embodiment of the invention, the corrected water gauge image data is converted into the actual scale value, the actual scale value is obtained through the calculation of the corresponding relation between scales and pixels, the control strategy is set, the related equipment parameters are automatically adjusted, and the real-time scale data is ensured to the database, so that the automatic water gauge acquisition data is generated.
Preferably, step S2 comprises the steps of:
step S21: performing double-flow and multi-path adaptive transmission processing on the automatic water gauge acquired data to generate water gauge pre-optimized transmission data;
step S22: scheduling and distributing the water gauge pre-optimized transmission data by utilizing multichannel dynamic (flow) scheduling processing to generate water gauge multichannel processing data;
step S23: carrying out real-time depth analysis processing on the multichannel processing data of the water gauge to generate parameter image data of the water gauge;
step S24: and carrying out distributed high-reliability storage processing on the water gauge parameter image data to generate water gauge distributed cloud data.
According to the invention, double-flow multipath adaptive transmission processing is carried out on the automatic water gauge collected data, water gauge pre-optimized transmission data are generated, the transmission speed and transmission quality of water gauge image data are improved, a plurality of transmission paths are adopted, the data packet loss rate and transmission delay in the transmission process are reduced, the water gauge pre-optimized transmission data are subjected to scheduling distribution processing by utilizing multichannel dynamic (flow) scheduling processing, so that water gauge multichannel processing data are generated, a multichannel dynamic scheduling algorithm can schedule a plurality of transmission channels in real time, reasonable distribution and scheduling are carried out according to the flow conditions of the transmission channels, scheduling distribution processing is carried out on the water gauge pre-optimized transmission data by utilizing the multichannel dynamic scheduling algorithm, data loss and transmission errors are avoided, real-time depth analysis processing is carried out on the water gauge multichannel processing data, so that water gauge parameter image data are generated, a depth analysis processing model can extract more accurate and precise water gauge parameters from the multichannel processing data through a deep learning algorithm.
As an example of the present invention, referring to fig. 3, a detailed implementation step flow diagram of step S2 in fig. 1 is shown, where step S2 includes:
step S21: performing double-flow and multi-path adaptive transmission processing on the automatic water gauge acquired data to generate water gauge pre-optimized transmission data;
in the embodiment of the invention, the automatic part water gauge data is transmitted to the central server through the network, the factors such as bandwidth, delay and the like are considered in the transmission process, a plurality of network paths are adopted for simultaneously transmitting the data, and the data transmission paths are dynamically adjusted according to the network quality, so that the water gauge pre-optimized transmission data is generated.
Step S22: scheduling and distributing the water gauge pre-optimized transmission data by utilizing multichannel dynamic (flow) scheduling processing to generate water gauge multichannel processing data;
in the embodiment of the invention, the water gauge pre-optimized transmission data is distributed to a plurality of data processing channels, meanwhile, the processing priority and the processing speed of each channel are dynamically adjusted according to factors such as data processing load, network quality and the like, a load balancing algorithm based on flow scheduling is adopted for scheduling processing, and data recombination and sequencing are carried out according to data processing results, so that the water gauge multi-channel processing data is generated.
Step S23: carrying out real-time depth analysis processing on the multichannel processing data of the water gauge to generate parameter image data of the water gauge;
in the embodiment of the invention, multichannel water gauge data are analyzed, water level related data are extracted, multiple regression analysis is adopted to analyze the water level related data, water level parameters and characteristics are extracted, and the water level parameters and characteristics are visualized into image data by using a filtering image processing algorithm, so that water gauge parameter image data are generated.
Step S24: and carrying out distributed high-reliability storage processing on the water gauge parameter image data to generate water gauge distributed cloud data.
In the embodiment of the invention, the water gauge parameter image data is divided into the data blocks, each data block is provided with a unique identifier, a certain amount of redundant copies are generated for each data block, when original data is lost or damaged, the redundant copies are used for recovering the data, each data block and the redundant copies thereof are stored in a plurality of independent storage nodes in a distributed mode, the distributed storage technology adopts a decentralization method, so that the data are distributed on the plurality of nodes, the single-point fault risk is reduced, and the water gauge distributed cloud data are generated.
Preferably step S22 comprises the steps of:
Step S221: generating water gauge routing data by utilizing water gauge routing depth identification processing based on water gauge pre-optimized transmission data;
step S222: performing self-adaptive multipath optimization processing on the water gauge routing data to generate water gauge shunt data;
step S223: performing data mining optimization processing on the water gauge shunt data to generate water gauge model optimization data;
step S224: and performing data lasting guarantee processing on the optimized data of the water gauge model by using distributed multi-channel storage processing to generate multi-channel processing data of the water gauge.
According to the method, water gauge route data are generated based on water gauge pre-optimized transmission data through water gauge route depth identification processing, key information and rules in the water gauge route data are accurately analyzed through depth identification technology, accuracy of the water gauge route data is improved, self-adaptive multipath optimization processing is conducted on the water gauge route data, water gauge shunt data are generated, an optimal modulation mode is automatically selected according to current network conditions through the self-adaptive modulation technology, optimal transmission effect is achieved, data integrity is guaranteed, data transportation cost and energy consumption are reduced, data mining optimization processing is conducted on the water gauge shunt data, water gauge model optimization data are generated, the water gauge model is optimized from multiple angles, analysis is conducted on water gauge images through the data mining technology, feature information is extracted, prediction accuracy and recognition rate of the water gauge model are optimized, network data in the water gauge transmission process are analyzed through the data mining technology, potential problems and optimization space are found, data lasting guarantee processing is conducted on the water gauge model optimization data through the distributed multichannel storage processing, read-write operation can be conducted through the channel technology, data storage efficiency is improved, data storage time is shortened, and data storage failure can be prevented from being caused by the fact that data are stored by the aid of multiple nodes in a single technology.
As an example of the present invention, referring to fig. 3, a detailed implementation step flow diagram of step S22 in fig. 3 is shown, where step S22 includes:
step S221: generating water gauge routing data by utilizing water gauge routing depth identification processing based on water gauge pre-optimized transmission data;
in the embodiment of the invention, the water gauge data transmission is optimized, the water gauge pre-optimized data is normalized, the data quality is improved, the influence of abnormal values is reduced, the cyclic neural network algorithm is utilized to extract the characteristics of periodicity and trend of the data from the pre-processed data, and the water gauge routing data containing information such as data sources, destinations, priorities and the like is generated according to the extracted characteristics.
Step S222: performing self-adaptive multipath optimization processing on the water gauge routing data to generate water gauge shunt data;
in the embodiment of the invention, the data packet transmission path is determined according to the characteristics and the priority of the data packet, the network topology structure and the bandwidth limiting factors among nodes are comprehensively considered, the optimal transmission path is selected for each data packet, the transmission path is dynamically adjusted, the network condition and the bandwidth utilization rate are monitored in real time, the network load is balanced, the blocking and the delay are reduced, and the water gauge shunt transmission data is generated.
Step S223: performing data mining optimization processing on the water gauge shunt data to generate water gauge model optimization data;
in the embodiment of the invention, proper data is selected from water gauge shunt data as sample data for data mining, the data is cleaned and preprocessed, abnormal data and missing values are removed, correlation, importance and degree of distinction among features in the sample data are screened and selected, the water gauge shunt data is subjected to data mining, the sample data is analyzed by adopting a data mining technology of clustering, classifying and association rules, the data rules and information are mined by analyzing the correlation and modes among the data, for example, similar data is divided into a group by utilizing clustering analysis, the data is analyzed according to each group of features, the data is divided into different categories by using a classification algorithm, the characteristics of each category are analyzed according to each category, the association among the data is mined by using the association rules, and then the mined data is analyzed and interpreted according to the association, so that optimized data of the water gauge model is generated.
Step S224: performing data lasting guarantee processing on the optimized data of the water gauge model by using distributed multi-channel storage processing to generate multi-channel processing data of the water gauge;
In the embodiment of the invention, the optimized data of the water gauge model is segmented into a plurality of datamation, the data blocks and the redundant copies are respectively stored on a plurality of storage nodes by using a distributed storage technology, the data is quickly accessed and restored by using a multi-channel technology, and the data is simultaneously read and written by using a plurality of channels, so that the data transmission speed is improved, and the multi-channel processing data of the water gauge is generated.
Preferably, step S3 comprises the steps of:
step S31: performing binarization rotation correction processing on the water gauge distributed cloud data to generate water gauge binary image data;
step S32: detecting and combining based on the water gauge binary image data by using a contour line distribution detection technology to generate water gauge area data;
step S33: performing morphological region segmentation processing on the water gauge region data to generate water gauge region topological structure data;
step S34: matrix summation calculation is carried out by utilizing a two-dimensional matrix region coordinate summation formula based on the water gauge communication region, so as to generate water gauge two-dimensional image data;
step S35: and calculating the edge scale difference of the two-dimensional image data of the water gauge by using a gradient edge weighting scale formula to generate a water gauge scale area image matrix.
According to the method, binary rotation correction processing is carried out on the water gauge distributed cloud data to generate water gauge binary image data, the binary image data only comprise two values, compared with the original image data, the binary image data needs less storage space, the data storage cost is reduced, for abnormal situations that the rotation angle of the water gauge is not greater than a preset threshold value, a program default processing mode can be automatically compatible, the processing efficiency and accuracy are improved, detection combination processing is carried out on the basis of the water gauge binary image data by utilizing a contour line distribution detection technology to generate water gauge region data, the water gauge region data can be automatically extracted, and the accuracy and the efficiency of water gauge detection are improved. Meanwhile, the method can adapt to different types of water gauge image data, morphological region segmentation processing is carried out on the water gauge region data, water gauge region topological structure data is generated, morphological processing is carried out on the water gauge region data, noise can be removed, images are smoothed, important features in the images are reserved, reliable basic data is provided for subsequent analysis processing, matrix summation calculation is carried out by utilizing a two-dimensional matrix region coordinate summation formula based on the water gauge communication region, water gauge two-dimensional image data is generated, the requirement on rapid processing of the water gauge region topological structure data is met, pixel summation of each communication region in the water gauge image can be rapidly and accurately obtained, basic data support is provided for subsequent water level calculation and analysis, edge graduation calculation is carried out on the water gauge two-dimensional image data by utilizing a gradient edge weighting graduation formula, a water gauge graduation region image matrix is generated, water gauge graduation information is effectively extracted and distinguished when graduation value difference is large, water gauge graduation information is accurate and reliable, and accuracy and stability of water gauge graduation calculation are improved.
As an example of the present invention, referring to fig. 4, a detailed implementation step flow diagram of step S3 in fig. 1 is shown, where step S3 includes:
step S31: performing binarization rotation correction processing on the water gauge distributed cloud data to generate water gauge binary image data;
in the embodiment of the invention, gray scale image is generated by gray scale image processing, gray scale image is binarized by using maximum inter-class contrast method, the gray scale image is converted into black-white binary image, rotation correction processing is performed on the water scale image by using Hough transform technology, and the horizontal direction is consistent with the scale mark direction of the water scale, so that water scale binary image data is generated.
Step S32: detecting and combining based on the water gauge binary image data by using a contour line distribution detection technology to generate water gauge area data;
in the embodiment of the invention, binary image data of a water gauge are read into a program, image data are processed by using a Canni edge operator to obtain image edge information, all contours of the image are detected by using a contour detection algorithm to generate a contour list, the contour distribution information in the image is found by using a line distribution detection algorithm and contains marked lines or other irrelevant lines in the water gauge to generate a line list, the contour list and the line list are combined, and a water gauge area is detected, so that water gauge area data are generated.
Step S33: performing morphological region segmentation processing on the water gauge region data to generate water gauge region topological structure data;
in the embodiment of the invention, based on the topological structure data of the water gauge area, morphological operation is utilized for the positioned rectangular connected areas of the suspected water gauge, small holes and small objects in the images are removed by utilizing opening operation (corrosion is performed before expansion), the connected pixel points in the water gauge images are marked as the same area by utilizing a connected area marking algorithm, the gravity center and the area of each connected area are calculated, and the rectangular connected areas meeting the standard are screened out through geometric features, so that the topological structure data of the water gauge area is generated.
Step S34: matrix summation calculation is carried out by utilizing a two-dimensional matrix region coordinate summation formula based on the water gauge communication region, so as to generate water gauge two-dimensional image data;
in the embodiment of the invention, matrix summation calculation is performed by utilizing a two-dimensional matrix region coordinate summation formula based on the water gauge communication region according to a digital and image processing technology, so as to generate water gauge two-dimensional image data.
Preferably, the two-dimensional matrix region coordinate summation formula in step S34 is as follows:
wherein the method comprises the steps ofRefers to two-dimensional image data of a water gauge, +.>Refers to the number of matrices, +. >Refers to a rectangular half constant index, ++>Refers to->Rectangular center abscissa,/->Is the ambiguity of the image area of the water gauge, +.>Refers to the abscissa of the rectangular center point, +.>Refers to the gray function of the water gauge image, +.>Refers to->Rectangular center ordinate,/>Refers to the ordinate of the rectangular center,/->Means that the water gauge image is in pixel coordinates +.>Luminance value of->Refers to coordinates +.>Red component value->Refers to coordinates +.>Green component value, ++>Refers to coordinates +.>Blue component value.
The invention provides a two-dimensional matrix region coordinate summationA formula which fully considers the two-dimensional image data of the water gaugeMatrix number->Rectangular half constant index->First->Rectangular center abscissa +.>Water gauge image area ambiguity ++>Rectangular center point abscissa +.>Gray function of water gauge image>First->Rectangular center ordinate +.>Rectangular center ordinate ∈ ->The water gauge image is in pixel coordinates +.>Luminance value->Finger coordinates->Red component value->Coordinates->Green component value +.>Coordinates->Blue component value->Generating the ambiguity of the area of the water gauge image according to the square half constant index and the gray constant of the water gauge image>And interactions between functions to form a functional relationship:
The method comprises the steps of determining the coordinate range of a water gauge area, representing the coordinate range as a matrix in a computer two-dimensional coordinate system by utilizing a filtering image processing algorithm, accurately calculating the value of each element, avoiding accumulation of calculation errors, improving calculation accuracy, receiving factor interference such as illumination, noise and the like when the dynamic matrix area is segmented, comprehensively considering and capturing the edge difference information of the water gauge graduation area, carrying out weighted calculation on the two-dimensional matrix of the water gauge area, eliminating interference factors such as illumination, noise and the like, carrying out integral calculation on a function in a rectangular area by utilizing calculus, realizing effective extraction and calculation on water gauge image data, reducing the influence of water wave vibration on image quality, leading calculation to achieve rapid convergence, saving calculation force, more accurately reflecting the water gauge graduation value by the combined calculation on a water gauge image gray function and pixel coordinates, and forming a functional relation by the interaction between the water gauge image gray function and the water gauge image brightness valueThe gray function is adjusted, so that the luminosity value distribution of the water gauge image is uniform, the image is clear and bright visually, weight information and adjustment items in the formula can be adjusted according to actual conditions and are applied to unused edge area image data, and the flexibility and applicability of an algorithm are improved.
Step S35: and calculating the edge scale difference of the two-dimensional image data of the water gauge by using a gradient edge weighting scale formula to generate a water gauge scale area image matrix.
In the embodiment of the invention, two-dimensional image data of the water gauge are input into a model according to a digital and image processing technology, and edge scale difference calculation is performed by using a gradient edge weighting scale formula, so that a water gauge scale area image matrix is generated.
Preferably, the gradient edge weighting scale formula in step S35 is as follows:
wherein the method comprises the steps ofRefers to a scale region image matrix of the water gauge, < >>Refers to the image width, +.>Refers to the image height, +.>Refers to two-dimensional weight index->Refers to a smoothed trailing edge intensity matrix, +.>Refers to the edge intensity matrix,/>Refers to gradient edge weight parameters, < >>Refers to Gaussian filter, ">Refers to the image at the position +.>Gradient of->Refers to screening edge location thresholds.
The invention provides a gradient edge weighting scale formula which fully considers the image matrix of the scale region of a water gaugeImage width->Image height +.>Two-dimensional weight index->Smooth trailing edge intensity matrix->Edge intensity matrix->Gradient edge weight parameter->Gaussian filter- >The image is in position->Gradient of->Screening for edge position threshold +.>And interrelationships between functions, forming the following functional relationships:
thereby realizing the generation of the image matrix of the scale region of the water gauge, reducing the complexity of data, improving the calculation efficiency, achieving rapid convergence in the calculation process, and optimizing the two-dimensional weight index by a gradient descent methodGradient edge weighting parameter->Gaussian filter->Thereby realizing the stability and the robustness of the generation of the water gauge area image matrix by smoothing the rear edge intensity matrixEdge intensity matrix->The function mapping model of the scale region is constructed, a scale region image matrix generating model with high complexity and nonlinearity is constructed, complex characteristics and structural information of a scale region of the scale can be captured, the scale region image matrix topology and geometric properties such as neighborhood relation, relative position and shape are comprehensively considered, and the accuracy of data is improvedBy edge intensity matrix->And Gaussian filter->The combination of the two is used for capturing the linear and nonlinear relations in the image matrix of the scale region of the water gauge, improving the modeling capability, improving the numerical stability through parameter optimization and adjustment, further reducing errors by utilizing error propagation, reducing the time complexity and the space complexity of an algorithm through optimization of a calculation process, meeting the real-time requirement, and utilizing a random gradient descent method to perform Gaussian filter >Optimizing and adjusting by continuously updating gradient edge weight parameter +.>Gradually reducing the loss function value, improving the signal-to-noise ratio of the image, and enhancing the signal. Preferably, step S4 comprises the steps of:
step S41: carrying out segmentation extraction line combination processing on the water gauge standardized region image data to generate segmentation linear fitting image data;
step S42: performing calibration fit scale extraction processing on the piecewise linear fit data to generate piecewise scale detection data;
step S43: performing data verification processing by using block chain segmentation scale verification processing to generate block scale verification data;
step S44: and carrying out dynamic logic relation detection processing on the block scale detection data to generate initial scale data.
The method comprises the steps of carrying out piecewise extraction line merging processing on water gauge standardized region image data to generate piecewise linear fitting image data, carrying out piecewise extraction and merging on the water gauge image to reduce the number of lines, thereby reducing the complexity of subsequent linear fitting calculation, improving the calculation efficiency, improving the accuracy and robustness of water gauge scale line extraction, carrying out calibration fitting scale extraction processing on piecewise linear fitting data to generate piecewise scale detection data, accurately extracting scale information in the water gauge image to realize detection of horizontal scales in the image, simultaneously, effectively avoiding errors caused by interference between vertical scales and horizontal scales, improving the accuracy and precision of water gauge image processing, generating block scale detection data by carrying out data verification processing by using block chain piecewise scale detection processing, realizing data decentralization, distributed storage and sharing by using block chain technology, effectively improving the safety, reliability and authenticity of data, effectively reducing the risk of data tampering by using block chain piecewise scale verification processing, thereby improving the reliability and reliability of data, carrying out automatic state detection on the block scale detection data, reducing the reliability and the reliability, carrying out logic state error detection, and reducing the initial state error, and the logic error detection, thus generating dynamic state error-prone data.
As an example of the present invention, referring to fig. 5, a detailed implementation step flow diagram of step S4 in fig. 1 is shown, where step S4 includes:
step S41: carrying out segmentation extraction line combination processing on the water gauge standardized region image data to generate segmentation linear fitting image data;
in the embodiment of the invention, segmentation extraction processing is carried out on standardized region data of a water gauge, the image data is divided into a plurality of continuous interval sections according to linear distribution characteristics of scale marks of the water gauge, images of each interval section are cut out according to edge positions, line merging processing is carried out on the image data of each interval section, lines with similar distances are merged into the same line, and fitting is carried out on the lines of each interval section based on a segmentation linear fitting technology, so that segmentation linear fitting image data is generated.
Step S42: performing calibration fit scale extraction processing on the piecewise linear fit data to generate piecewise scale detection data;
in the embodiment of the invention, the piecewise linear fitting data is subjected to calibration extraction processing to obtain piecewise scale detection data of each section of area, the piecewise linear fitting data is processed by adopting a projection method and a gradient method, the scale lines in each section of area are extracted, and the scale lines are segmented and grouped, so that the piecewise scale detection data is generated.
Step S43: performing data verification processing by using block chain segmentation scale verification processing to generate block scale verification data;
in the embodiment of the invention, the segmented scale detection data is verified by using a blockchain technology, a trust system for decentralization is constructed by using the blockchain technology to generate the block scale detection data, and digital signature and hash value verification are performed on each block, so that the block scale detection data is generated.
Step S44: and carrying out dynamic logic relation detection processing on the block scale detection data to generate initial scale data.
In the embodiment of the invention, block scale inspection data are acquired, wherein the block scale inspection data comprise information such as block positions of water gauge images, positions of scale lines, scale values and the like, the scale lines are ordered and grouped according to the position information of the scale lines, the adjacent lines are divided into the same group, the distance calculation and the scale difference calculation between the adjacent lines are carried out on each group of scale lines, whether the scales meet standard requirements or not is judged, if abnormal scales exist, the abnormal scales are marked and further processed, dynamic logic relation detection processing is carried out according to the marks and related information of the abnormal scales, the logic relation model is established, the logic relation between the abnormal scales and other scales is analyzed, the operations such as adjustment, deletion, combination and the like of the scales are carried out, the accuracy and the continuity of the scale data are ensured, the generation of initial scale data is carried out on the adjusted scale data, and the initial water gauge data are generated according to the scale data which are subjected to the logic relation detection processing.
Preferably, step S5 comprises the steps of:
step S51: performing image definition change processing on the initial scale data by adopting an adaptive image definition extraction strategy to generate adaptive definition image data;
step S52: performing layer definition comparison processing according to the self-adaptive definition image data to generate low-resolution fuzzy layer data;
step S53: according to the low-resolution fuzzy layer data, constructing a training model by utilizing a residual network structure neural network algorithm to generate a calibration recognition training set;
step S54: and performing recognition processing on the calibration recognition training by utilizing residual network water gauge calibration processing to generate a water gauge calibration recognition model.
According to the invention, the image definition change processing is carried out on the initial scale data by adopting the self-adaptive image definition extraction strategy, so that self-adaptive definition image data is generated, and the definition problem in the water gauge image processing process is solved by adopting the self-adaptive definition extraction strategy, so that the accuracy and reliability of water gauge scale detection are improved. Meanwhile, the self-adaption of the strategy can process different types of image data, the application range is wide, the method has good practicability, higher-level water gauge scale detection is realized, the image layer definition comparison processing is carried out according to the self-adaption definition image data, low-resolution fuzzy image layer data is generated, the outline and detail of the low-resolution image layer are accurately detected, the low-resolution fuzzy image layer data with higher resolution is generated, the accuracy and precision of image processing are improved, errors and distortion generated in the image processing process are avoided, a calibration recognition training set is formed by constructing a training model according to the low-resolution fuzzy image layer data by utilizing a residual network structure neural network algorithm, the system learning capacity and the data analysis capacity are effectively improved, the system can better learn the low-resolution fuzzy image layer data, the calibration recognition training set is generated according to the characteristics, the system can recognize and quantitatively analyze the water gauge image under different scenes, the applicability and the flexibility are enhanced, the calibration recognition training is carried out by utilizing the residual network calibration processing, the calibration recognition model is generated, the calibration recognition model is effectively utilized, the calibration accuracy and the calibration standard is improved, the calibration accuracy and the calibration standard is realized, and the calibration accuracy is improved, and the calibration standard is realized.
As an example of the present invention, referring to fig. 6, a detailed implementation step flow diagram of step S5 in fig. 1 is shown, where step S5 includes:
step S51: performing image definition change processing on the initial scale data by adopting an adaptive image definition extraction strategy to generate adaptive definition image data;
in the embodiment of the invention, a water gauge area is cut according to initial scale data to obtain a plurality of images, fourier transformation of the images is calculated to obtain a frequency spectrogram, energy distribution of the frequency spectrogram is calculated to obtain a definition score of the images, the definition score of the images is determined by setting a threshold value of the definition score, the images with the definition score higher than the threshold value are regarded as clear images, the images with the definition score lower than the threshold value are regarded as fuzzy images, cutting processing is respectively carried out, different neural network models are respectively trained for the clear images and the fuzzy images, and the neural network models are respectively used for pool bar calibration identification of the clear images and the fuzzy images, so that self-adaptive definition image data are generated.
Step S52: performing layer definition comparison processing according to the self-adaptive definition image data to generate low-resolution fuzzy layer data;
in the embodiment of the invention, the image layer definition comparison processing is carried out according to the self-adaptive definition image data, the low-resolution fuzzy image layer data is generated, different processing modes are adopted according to different image resolutions, and when the image resolution is high, the scale of the water gauge scale on the image is identified by utilizing the optical character identification model.
Step S53: according to the low-resolution fuzzy layer data, constructing a training model by utilizing a residual network structure neural network algorithm to generate a calibration recognition training set;
in the embodiment of the invention, the generated low-resolution fuzzy layer data is used as input data, scale position information of a water gauge is manually marked as output data, a neural network model of a residual network structure is constructed by using the marking data, training is carried out, model parameters are adjusted, training data is added, and thus a calibration recognition training set is generated.
Step S54: and performing recognition processing on the calibration recognition training by utilizing residual network water gauge calibration processing to generate a water gauge calibration recognition model.
In the embodiment of the invention, the generated calibration recognition training set is utilized to train the neural network model of the residual network structure, and the trained model is tested and verified to evaluate the performance of the model, so that the water gauge calibration recognition model is generated.
Preferably, step S6 comprises the steps of:
step S61: based on the water gauge calibration recognition model, acquiring piecewise linear fitting image data to perform water level region image preprocessing, and generating water level image preprocessing data;
step S62: generating back-image adaptive water level output data by utilizing water level back-image automatic compatible processing on the water level image preprocessing data;
Step S63: and carrying out residual network end-to-end training prediction recognition processing on the reflection adaptive water level output data to generate water level perception data.
According to the invention, based on a water gauge calibration recognition model, piecewise linear fitting image data is obtained to perform water level region image preprocessing, water level image preprocessing data is generated, the piecewise linear fitting image data is preprocessed, the calculated amount of subsequent processing is reduced, the speed and efficiency of water level detection are accelerated, the processing efficiency is improved, the robustness of a system is improved, the water level image preprocessing data is utilized to generate back-image adaptive water level output data by water level back-image automatic compatible processing, the back-image adaptive water level output data can adapt to the back-image condition in an actual scene, the applicability and reliability of the water level output data are improved, the actual requirement is met, residual network end-to-end training prediction recognition processing is performed on the back-image adaptive water level output data, water level perception data is generated, the water level perception task is automatically completed by utilizing end-to-end training and prediction processing, the manual recognition workload and error rate are reduced, the recognition accuracy of water level perception is improved, the reliability of the water level monitoring data is improved, the reliability of the water level detection is improved, the residual network model can adaptively learn and recognize image features under different water levels, and self-adaptive water level perception is supported.
As an example of the present invention, referring to fig. 7, a detailed implementation step flow diagram of step S6 in fig. 1 is shown, where step S6 includes:
step S61: based on the water gauge calibration recognition model, acquiring piecewise linear fitting image data to perform water level region image preprocessing, and generating water level image preprocessing data;
in the embodiment of the invention, based on a water gauge calibration recognition model, piecewise linear fitting image data is obtained, a Gaussian filtering algorithm is utilized to denoise an image, the water gauge calibration in the image is recognized by the water gauge calibration recognition model, the corresponding relation between the water gauge calibration and the actual length is obtained, and the image is scaled and stretched according to the corresponding relation, so that the water level area in the image can be correctly mapped to the actual water level height, and water level image preprocessing data is generated.
Step S62: generating back-image adaptive water level output data by utilizing water level back-image automatic compatible processing on the water level image preprocessing data;
in the embodiment of the invention, the water level image and the processing data are subjected to the back-image detection to judge whether the water gauge back-image exists, if the water gauge back-image exists and is positioned at the middle position of the E, the data near the middle position of the E is extracted, the data are identified by utilizing a residual network digital identification model, if the number is consistent with the number under the normal condition of the E, the water gauge back-image exists can be judged, the water level area is subjected to mirror image overturning according to a back-image mirror image processing algorithm, and the water level area is subjected to back-image automatic compatible processing, so that the back-image adaptive water level output data are generated.
Step S63: performing residual network end-to-end training, predicting and identifying processing on the reflection adaptive water level output data to generate water level perception data;
in the embodiment of the invention, the reflection adaptive water level output data is randomly divided into a training set and a testing set, the training set is subjected to data enhancement operation, a residual error network structure is selected according to the characteristics of the data set and task requirements to carry out model adjustment and optimization, a gradient descent algorithm is adopted to train the selected model, cross verification and parameter adjustment operation are carried out, the testing set is utilized to evaluate the trained model, and the trained model is applied to the prediction recognition process of water level perception data, so that the water level perception data is generated.
The foregoing is only a specific embodiment of the invention to enable those skilled in the art to understand or practice the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (6)

1. A water level measurement method based on image recognition, the method comprising:
step S1: the automatic camera is utilized to perform automatic water gauge image acquisition processing on the water gauge, and automatic water gauge acquisition data are generated;
step S2: generating water gauge distributed cloud data by utilizing media cloud distribution processing based on automatic water gauge acquisition data;
step S3, based on the water gauge distributed cloud data, performing morphological contour detection and segmentation processing on the water gauge to generate water gauge scale region image data, wherein the step comprises the following steps:
step S31: performing binarization rotation correction processing on the water gauge distributed cloud data to generate water gauge binary image data;
step S32: detecting and combining based on the water gauge binary image data by using a contour line distribution detection technology to generate water gauge area data;
step S33: performing morphological region segmentation processing on the water gauge region data to generate water gauge region topological structure data;
step S34: matrix summation calculation is carried out by utilizing a two-dimensional matrix region coordinate summation formula based on the water gauge communication region, so as to generate water gauge two-dimensional image data;
the two-dimensional matrix region coordinate summation formula specifically comprises:
wherein the method comprises the steps ofRefers to two-dimensional image data of a water gauge, +. >Refers to the number of matrices, +.>Refers to the matrix half constant index, +.>Refers to->Central abscissa of matrix,/->Is the ambiguity of the image area of the water gauge, +.>Refers to the abscissa of the central point of the matrix, +.>Refers to the gray function of the water gauge image, +.>Refers to->The central ordinate of the matrix,/>Refers to the ordinate of the center of the matrix,/->Means that the water gauge image is in pixel coordinates +.>Luminance value of->Refers to coordinates +.>Red component value->Refers to coordinates +.>Green component value, ++>Refers to coordinatesA blue component value;
step S35: performing edge scale difference calculation on the two-dimensional image data of the water gauge by using a gradient edge weighting scale formula to generate image data of a scale region of the water gauge;
the gradient edge weighting scale formula specifically comprises the following steps:
wherein the method comprises the steps ofRefers to the image data of the scale region of the water gauge, < + >>Refers to the image width, +.>Refers to the image height, +.>Refers to two-dimensional weight index->Refers to a smoothed trailing edge intensity matrix, +.>Refers to the edge intensity matrix,/>Refers to gradient edge weight parameters, < >>Refers to Gaussian filter, ">Refers to the image at the position +.>Gradient of->Refers to screening edge position thresholds;
step S4, based on the water gauge scale region image data, performing image linear fitting verification processing on the water gauge by using a block chain technology, and generating initial scale data, wherein the step comprises the following steps:
Step S41: carrying out segmentation extraction line combination processing on the water gauge scale region image data to generate segmentation linear fitting image data;
step S42: performing calibration fit scale extraction processing on the piecewise linear fit image data to generate piecewise linear scale detection data;
step S43: performing data verification processing on the piecewise linear scale detection data by using a block chain technology to generate block scale detection data;
step S44: performing dynamic logic relation detection processing on the block scale test data to generate initial scale data;
step S5: performing model construction training treatment on the initial scale data by using a neural network algorithm to generate a water gauge scaling recognition model;
step S6: and performing model training treatment on the water gauge scales by utilizing resolution self-adaptive scale calibration calculation to generate water level perception data.
2. The method according to claim 1, wherein the specific steps of step S1 are:
step S11: performing image calibration pretreatment on the water gauge environment image by using an automatic camera to generate original water gauge image data;
step S12: performing image enhancement denoising processing based on the original water scale image data to generate denoised water scale image data;
Step S13: dividing and positioning the denoised water gauge image data by using a digital water gauge image recognition method to generate calibrated divided water gauge image data;
step S14: performing data verification and correction processing on the calibrated and divided water gauge image data to generate corrected water gauge image data;
step S15: and (3) carrying out automatic feedback control optimization processing on the corrected water gauge image data to generate automatic water gauge acquisition data.
3. The method according to claim 2, wherein the specific steps of step S2 are:
step S21: performing double-flow and multi-path adaptive transmission processing on the automatic water gauge acquired data to generate water gauge pre-optimized transmission data;
step S22: scheduling and distributing the water gauge pre-optimized transmission data by utilizing multi-channel dynamic scheduling processing to generate water gauge multi-channel processing data;
step S23: carrying out real-time depth analysis processing on the multichannel processing data of the water gauge to generate parameter image data of the water gauge;
step S24: and carrying out distributed high-reliability storage processing on the water gauge parameter image data to generate water gauge distributed cloud data.
4. A method according to claim 3, wherein the specific steps of step S22 are:
Step S221: generating water gauge routing data by utilizing water gauge routing depth identification processing based on water gauge pre-optimized transmission data;
step S222: performing self-adaptive multipath optimization processing on the water gauge routing data to generate water gauge shunt data;
step S223: performing data mining optimization processing on the water gauge shunt data to generate water gauge model optimization data;
step S224: and performing data lasting guarantee processing on the optimized data of the water gauge model by using distributed multi-channel storage processing to generate multi-channel processing data of the water gauge.
5. The method according to claim 4, wherein the specific steps of step S5 are:
step S51: performing image definition change processing on the initial scale data by adopting an adaptive image definition extraction strategy to generate adaptive definition image data;
step S52: performing layer definition comparison processing according to the self-adaptive definition image data to generate low-resolution fuzzy layer data;
step S53: according to the low-resolution fuzzy layer data, constructing a training model by utilizing a residual network structure neural network algorithm to generate a calibration recognition training set;
step S54: and performing recognition processing on the calibration recognition training by utilizing residual network water gauge calibration processing to generate a water gauge calibration recognition model.
6. The method according to claim 5, wherein the specific steps of step S6 are:
step S61: based on the water gauge calibration recognition model, acquiring piecewise linear fitting image data to perform water level region image preprocessing, and generating water level image preprocessing data;
step S62: generating back-image adaptive water level output data by utilizing water level back-image automatic compatible processing on the water level image preprocessing data;
step S63: and carrying out residual network end-to-end training prediction recognition processing on the reflection adaptive water level output data to generate water level perception data.
CN202310636856.7A 2023-06-01 2023-06-01 Water level measurement method based on image recognition Active CN116385735B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310636856.7A CN116385735B (en) 2023-06-01 2023-06-01 Water level measurement method based on image recognition

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310636856.7A CN116385735B (en) 2023-06-01 2023-06-01 Water level measurement method based on image recognition

Publications (2)

Publication Number Publication Date
CN116385735A CN116385735A (en) 2023-07-04
CN116385735B true CN116385735B (en) 2023-09-01

Family

ID=86963743

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310636856.7A Active CN116385735B (en) 2023-06-01 2023-06-01 Water level measurement method based on image recognition

Country Status (1)

Country Link
CN (1) CN116385735B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117288441A (en) * 2023-10-16 2023-12-26 中国气象科学研究院 Langley calibration auxiliary method and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109522889A (en) * 2018-09-03 2019-03-26 中国人民解放军国防科技大学 Hydrological ruler water level identification and estimation method based on image analysis
CN111680606A (en) * 2020-06-03 2020-09-18 淮河水利委员会水文局(信息中心) Low-power-consumption water level remote measuring system based on artificial intelligence cloud identification water gauge
CN112910974A (en) * 2021-01-21 2021-06-04 贵州电网有限责任公司 System and method based on block chain system architecture
KR102319084B1 (en) * 2021-04-23 2021-11-02 주식회사 아르스루퍼 Intelligent water level detecting apparatus and method
CN113971779A (en) * 2021-10-29 2022-01-25 中国水利水电科学研究院 Water gauge automatic reading method based on deep learning

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006002687A2 (en) * 2004-06-30 2006-01-12 Swiss Reinsurance Company Method and system for automated location-dependent recognition of flood risks
AR109623A1 (en) * 2018-02-16 2019-01-09 Pescarmona Enrique Menotti PROCESS AND SYSTEM OF ANALYSIS AND HYDROLOGICAL MANAGEMENT FOR BASINS
US20210374466A1 (en) * 2020-05-26 2021-12-02 Zhejiang University Water level monitoring method based on cluster partition and scale recognition

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109522889A (en) * 2018-09-03 2019-03-26 中国人民解放军国防科技大学 Hydrological ruler water level identification and estimation method based on image analysis
CN111680606A (en) * 2020-06-03 2020-09-18 淮河水利委员会水文局(信息中心) Low-power-consumption water level remote measuring system based on artificial intelligence cloud identification water gauge
CN112910974A (en) * 2021-01-21 2021-06-04 贵州电网有限责任公司 System and method based on block chain system architecture
KR102319084B1 (en) * 2021-04-23 2021-11-02 주식회사 아르스루퍼 Intelligent water level detecting apparatus and method
CN113971779A (en) * 2021-10-29 2022-01-25 中国水利水电科学研究院 Water gauge automatic reading method based on deep learning

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
AI技术在水尺计重领域应用研究;杨卫星 等;《中国口岸科学技术》;第72-76页 *

Also Published As

Publication number Publication date
CN116385735A (en) 2023-07-04

Similar Documents

Publication Publication Date Title
CN114419025A (en) Fiberboard quality evaluation method based on image processing
CN104331710B (en) On off state identifying system
CN110930390B (en) Chip pin missing detection method based on semi-supervised deep learning
CN116385735B (en) Water level measurement method based on image recognition
CN113205063A (en) Visual identification and positioning method for defects of power transmission conductor
CN115115638B (en) Oil leakage detection and judgment method for hydraulic system
TW202127371A (en) Image-based defect detection method and computer readable medium thereof
CN105225523A (en) A kind of parking space state detection method and device
CN110288624A (en) Detection method, device and the relevant device of straightway in a kind of image
CN113706523A (en) Method for monitoring belt deviation and abnormal operation state based on artificial intelligence technology
CN113240623A (en) Pavement disease detection method and device
CN113435452A (en) Electrical equipment nameplate text detection method based on improved CTPN algorithm
CN115861307A (en) Fascia gun power supply drive plate welding fault detection method based on artificial intelligence
CN111709964A (en) PCBA target edge detection method
CN114494695A (en) Intelligent water conservancy urban and rural waterlogging level monitoring and early warning method and device
CN114332781A (en) Intelligent license plate recognition method and system based on deep learning
CN115880683B (en) Urban waterlogging ponding intelligent water level detection method based on deep learning
CN109738752A (en) A kind of fast imaging method for grounded screen maintenance
CN115597494B (en) Precision detection method and system for prefabricated part preformed hole based on point cloud
CN116612461A (en) Target detection-based pointer instrument whole-process automatic reading method
CN106295642B (en) License plate positioning method based on fault tolerance rate and texture features
CN104504702A (en) Cement notch pavement crack recognition method based on square lattice searching method
CN111627018B (en) Steel plate surface defect classification method based on double-flow neural network model
CN112767365A (en) Flaw detection method
CN112801963A (en) Video image occlusion detection method and system

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