Method and system for dynamic correction of geographic coordinates
By introducing AIS data and image coordinate matching into maritime supervision and constructing a dynamic correction mechanism, the positioning deviation problem caused by environmental changes in video surveillance equipment was solved, automated mapping model updates were achieved, maintenance costs were reduced, and positioning accuracy was improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- WEIYA (SHANGHAI) DIGITAL TECH CO LTD
- Filing Date
- 2026-05-20
- Publication Date
- 2026-07-31
AI Technical Summary
In current maritime supervision, the positioning deviation of video surveillance equipment accumulates due to environmental changes, requiring regular manual recalibration, which is costly and inefficient.
By introducing AIS data as a benchmark and combining it with image coordinates for matching and filtering, a dynamic correction mechanism is constructed to automatically update the mapping model, adapt to environmental changes, and reduce manual intervention.
It improves the stability and accuracy of video latitude and longitude mapping, reduces operation and maintenance costs, and adapts to environmental changes in various maritime scenarios.
Smart Images

Figure CN122492882A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of maritime traffic safety supervision technology, and in particular to a method and system for dynamic correction of geographic coordinates. Background Technology
[0002] In maritime supervision, video surveillance is a core technological tool. Its key requirement is to map the pixel coordinates of ships in the video to real latitude and longitude, providing support for supervision, dispatching and other work.
[0003] Existing ship latitude and longitude mapping mostly adopts static calibration schemes, which establish mapping models by manually setting up fixed calibration points. Some schemes only use simple manual correction or preliminary combination with external data, without forming a systematic and automated correction mechanism, and still rely on manual model optimization.
[0004] However, in practical applications, outdoor monitoring equipment is easily affected by the environment, resulting in slight displacement or posture changes. These changes are magnified in the image, causing the original mapping model parameters to become invalid and the positioning deviation to increase. Moreover, the mapping model is static and cannot automatically adapt to environmental changes. Long-term operation can easily lead to the accumulation of deviations, requiring manual recalibration periodically, which results in high maintenance costs and low efficiency. Summary of the Invention
[0005] Based on this, it is necessary to provide a dynamic correction method and system for geographic coordinates to address the aforementioned technical issues. This method uses AIS data as a location benchmark, matches and filters it with corresponding image coordinates, iteratively optimizes the mapping model, and achieves automatic data collection and dynamic model correction without manual intervention. It can adapt to changes in the camera equipment environment, fit various maritime scenarios, eliminate manual calibration, reduce operation and maintenance costs, and improve the stability and accuracy of ship video latitude and longitude mapping.
[0006] The first aspect of the present invention provides a dynamic correction method for geographic coordinates. The correction method includes the following steps: acquiring the image coordinates of a moving target and the reference geographic coordinates output by an external recognition system; matching the image coordinates with the reference geographic coordinates to determine a confidence score, and filtering correction data that reaches a preset threshold based on the confidence score; when the correction data meets the triggering condition, updating the mapping model between the image coordinates and the reference geographic coordinates based on the correction data and the confidence score, and converting the image coordinates into corrected geographic coordinates for output.
[0007] In one embodiment, image coordinates are matched with reference geographic coordinates based on multiple matching dimensions. When the image coordinates and reference geographic coordinates are consistent in all matching dimensions, a correspondence between the image coordinates and the corresponding reference geographic coordinates is established.
[0008] In one embodiment, the confidence score is determined by a weighted product operation based on the satisfaction level of the matching dimension and the corresponding weight coefficient, and the correction data when the confidence score reaches a preset threshold is used to update the mapping model. The functional expression of the confidence score is: ;in, Confidence score , For the first Satisfaction of each matching dimension For the first Weight coefficients for each matching dimension The number of dimensions to match.
[0009] In one embodiment, the triggering conditions include the cumulative number of correction data reaching a preset number threshold, and the distribution coverage of the correction data within a preset area reaching a preset coverage threshold.
[0010] In one embodiment, updating the mapping model includes the following steps: constructing an error function based on the correction data and confidence scores, and determining the updated mapping model based on the error function, wherein the expression for the error function is: = ;in, The longitude is obtained by mapping image coordinates. Latitude obtained from image coordinate mapping The longitude corresponding to the reference geographic coordinates matched for the i-th correction data. The latitude corresponding to the reference geographic coordinates matched for the i-th correction data.
[0011] In one embodiment, the correction data is solved based on the updated mapping model to obtain the updated homography matrix. Based on the homography matrix, a bidirectional transformation between image coordinates and real geographic location coordinates is performed. The bidirectional transformation includes forward mapping and inverse mapping. Forward mapping is used to convert the reference geographic coordinates into planar coordinates and then map them into image coordinates through the homography matrix. Inverse mapping is used to convert the image coordinates into planar coordinates through the inverse of the homography matrix and then convert them into corrected geographic coordinates.
[0012] In one embodiment, the correction data is cleaned, and the mapping model is updated based on the cleaned correction data meeting the triggering conditions.
[0013] In one embodiment, the cleaning process includes the following steps: based on the motion trajectory of the moving target, filtering the correction data whose displacement between adjacent correction data satisfies the theoretical displacement threshold, the theoretical displacement threshold being determined based on the motion speed of the moving target; identifying the main clusters from the correction data through cluster analysis, and filtering the correction data of the main clusters.
[0014] In one embodiment, the external identification system is the Automatic Identification System (AIS), and the reference geographic coordinates are extracted from the AIS message data.
[0015] A second aspect of the present invention provides a dynamic correction system for geographic coordinates. The correction system includes an acquisition module, a matching module, and an update module. The acquisition module is used to acquire the image coordinates of a moving target and the reference geographic coordinates output by an external recognition system. The matching module is configured to match the image coordinates and the reference geographic coordinates based on a matching dimension to determine a confidence score and correction data. The update module is configured to update the mapping model between the image coordinates and the reference geographic coordinates based on the correction data and the confidence score when the correction data meets the triggering conditions, and convert the image coordinates into corrected geographic coordinates for output.
[0016] The technical effects of this invention are: 1. This invention introduces the benchmark geographic coordinates output by an external identification system as a real-time feedback signal to construct a detection-matching-correction closed-loop mechanism, transforming the static calibration of the traditional scheme into dynamic correction. It can automatically complete the correction and update of the mapping model without the need for regular manual on-site calibration, reducing the dependence on manual calibration and maintenance costs.
[0017] 2. This invention uses a joint determination of multiple matching dimensions, such as position mapping, timestamp synchronization, speed, and heading angle, and employs weighted product operations to calculate confidence scores. It utilizes the weakest link effect mechanism to screen high-quality data that matches across all dimensions, eliminating mismatches and low-quality data, thus ensuring the credibility of the correction data participating in model updates.
[0018] 3. This invention ensures that model updates have sufficient sample statistics and spatial distribution representativeness by setting dual triggering conditions: a threshold for the cumulative number of correction data and a threshold for spatial distribution coverage. This avoids model overfitting and correction bias caused by insufficient data or local concentration. At the same time, data cleaning is an optional step. In the early stage of data accumulation, cleaning can be skipped and updates can be triggered directly, avoiding the loss of data due to erroneous data removal and thus balancing data quality and sample sufficiency.
[0019] 4. This invention introduces confidence scores as weighting coefficients into the error function, enabling high-quality calibration data to dominate parameter optimization, suppressing the interference of low-confidence noise data on model parameters, guiding the mapping model to evolve towards a more accurate direction, and improving correction accuracy.
[0020] 5. The closed-loop dynamic correction mechanism constructed in this invention can automatically adapt to changes in geometric relationships caused by environmental factors such as tidal changes, camera micro-displacement, and focal length changes. With the continuous accumulation of correction data and multiple updates of the model, the positioning accuracy gradually improves and remains stable over a long period of time, solving the problem of cumulative deviation caused by environmental changes in traditional static calibration. Attached Figure Description
[0021] Figure 1 This is a schematic diagram of the overall process of the dynamic correction method for geographic coordinates according to an embodiment of the present invention. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0023] Example 1: like Figure 1 As shown, this embodiment provides a dynamic correction method for geographic coordinates, which solves the problem of decreased positioning accuracy caused by environmental changes in static calibration parameters in the prior art. It uses AIS data as a reference to match image coordinates, filters correction data and iteratively optimizes the mapping model, realizes automatic collection of correction data and dynamic correction of the model, improves the mapping accuracy of video pixel coordinates to real geographic locations, and can adapt to environmental changes without manual calibration, ensuring the stability and accuracy of ship video latitude and longitude mapping.
[0024] Specifically, the method of this embodiment includes the following steps: Step S100: Obtain the image coordinates of the moving target and the reference geographic coordinates output by the external recognition system.
[0025] Specifically, the moving target can be a ship, floating object, or other mobile carrier in a maritime monitoring scenario. Image coordinates refer to the video images captured by video acquisition equipment, such as surveillance cameras. Baseline geographic coordinates refer to the real geographic latitude and longitude information provided by an external identification system. In this embodiment, the external identification system is preferably an Automatic Identification System (AIS), which can broadcast information such as the ship's identity, location, and speed in real time. The system detects and tracks moving targets in the image through video analysis algorithms, extracts their image coordinates, and simultaneously obtains the target's baseline geographic coordinates through the AIS, providing a data basis for subsequent matching and correction. Furthermore, the external identification system is not limited to AIS; it can also be a radar system, a BeiDou / GPS positioning terminal, or other information sources capable of providing high-precision geographic coordinates, as long as its data can be associated with the video target.
[0026] Step S200: Match the image coordinates with the reference geographic coordinates to determine the confidence score and correction data.
[0027] Specifically, because there may be time differences, ID inconsistencies, or detection errors between the targets detected in the video and those reported by the external recognition system, directly using the data would cause the model to crash. Therefore, this step aligns data from different sources through multi-dimensional association matching. The matching process not only determines whether the two points to the same physical entity but also calculates a confidence score. The confidence score quantifies the reliability of the match. For example, if the location of the target in the image highly overlaps with the AIS predicted location and the direction of movement is consistent, the confidence score is high; conversely, if there is a large deviation, the confidence score is low. Correction data refers to the image coordinates-reference geographic coordinates pairs formed after successful matching. These data pairs will serve as training samples for the correction model. By introducing the confidence score, the system can automatically filter out high-quality samples and eliminate noisy data caused by false detections, missed detections, or data delays, ensuring the accuracy of the correction source.
[0028] Step S300: When the correction data meets the triggering condition, update the mapping model between the image coordinates and the reference geographic coordinates based on the correction data and confidence score, and convert the image coordinates into corrected geographic coordinates for output.
[0029] Specifically, this step is the core of dynamic correction. Traditional static calibration is a one-time process, while this invention constructs a closed-loop feedback mechanism. Triggering conditions determine when to initiate a model update. For example, when the accumulated correction data reaches a certain amount, or when the data distribution covers a key area of the monitored region, an update is triggered. This mechanism avoids model oscillations caused by a small amount of erroneous data and prevents the waste of computational resources caused by frequent updates. When updating the mapping model, the correction data is used to optimize the current mapping parameters, such as the homography matrix parameters. Data with high confidence scores have a greater weight in the optimization, thereby guiding the model to evolve towards greater accuracy. Finally, using the updated model, the image coordinates detected by any video can be converted into high-precision geographic coordinates in real time. Through the above scheme, this embodiment achieves the transformation from static calibration to dynamic evolution, automatically adapting to environmental factors such as tidal changes and camera micro-displacements, maintaining high-precision positioning over a long period.
[0030] Example 2: This embodiment, based on Embodiment 1, provides a detailed description of the specific implementation of the matching step. In this embodiment, the external identification system is preferably an Automatic Identification System (AIS), and the reference geographic coordinates are extracted from the AIS message data. Specifically, the AIS system can broadcast dynamic information such as the ship's unique identification code (MMSI), latitude and longitude, heading, and speed in real time. This information is captured by the receiving unit of the monitoring terminal via radio signals, providing a high-precision external reference for target matching in video images. It should be understood that in other embodiments, the external identification system can also be a radar tracking system, a BeiDou / GPS positioning terminal, or other sensor systems capable of providing target identity and location information; this invention does not limit this.
[0031] After acquiring AIS data, the system executes sub-step S201 of step S200: matching image coordinates with reference geographic coordinates based on multiple matching dimensions. When the image coordinates and reference geographic coordinates are consistent across all matching dimensions, a correspondence is established between the image coordinates and the corresponding reference geographic coordinates. Specifically, the matching dimensions include, but are not limited to, location, heading angle, speed, and timestamp. Location refers to converting the latitude and longitude provided by AIS into image pixel coordinates using the current mapping model, calculating the Euclidean distance between these coordinates and the pixel coordinates of the ship detected in the video, and determining that the location is consistent if the distance is less than a preset distance threshold, such as 50 pixels. Heading angle refers to extracting the visual heading angle of the ship in the video, for example, calculating it based on the major axis of the ship's outline, and comparing it with the heading angle in the AIS data. If the absolute value of the difference is less than a preset angle threshold, such as 15 degrees, then the heading is consistent. Speed refers to calculating the visual speed of the ship in the video, for example, calculating it based on the pixel displacement of adjacent frames, converting it to physical units, and comparing it with the AIS speed. If the ratio is within a preset range, such as [0.5, 2.0], then the speed is consistent. Timestamp refers to comparing the timestamp of the video frame with the timestamp of the AIS data. If the time difference is less than a preset time threshold, such as 5 seconds, then the time is consistent. Only when all the above criteria are met simultaneously does the system consider the video target and the AIS target to point to the same physical entity, thus establishing a one-to-one correspondence. This multi-dimensional joint judgment logic avoids mismatches caused by single-dimensional data anomalies, such as AIS heading jumps or video detection drift, thus improving the reliability of the correction data source.
[0032] After establishing the correspondence, the system executes sub-step S202: calculating the confidence score. The confidence score is determined by a weighted product operation based on the satisfaction level of the matching dimension and the corresponding weight coefficients, and the correction data when the confidence score reaches a preset threshold is used to update the mapping model. The functional expression for the confidence score is: ; in, The confidence score , For the first Satisfaction of each matching dimension For the first Weight coefficients for each matching dimension The number of dimensions to match.
[0033] Since ∈[0,1], ∈[0,1], therefore ∈[0,1], this embodiment performs matching operations based on four dimensions: position, timestamp, speed, and heading angle, and uses a weighted product method to calculate the matching confidence score. Where: Let be the matching confidence score of the i-th corrected data. For the satisfaction of the location mapping dimension, For the satisfaction of the timestamp dimension, For the satisfaction of the speed dimension, For the satisfaction of the heading angle dimension, =0.4 is the weight coefficient for the location mapping dimension. =0.3 is the weighting coefficient for the timestamp dimension. =0.2 is the weighting coefficient for the speed dimension. =0.1 is the weighting coefficient for the heading angle dimension.
[0034] Satisfaction is a quantitative indicator used to characterize the quality of matching in this dimension. The value range is [0,1]. A higher satisfaction score indicates a more accurate match for that dimension. For example, for the position mapping dimension, the smaller the Euclidean distance, the closer the satisfaction score is to 1; for the heading angle dimension, the smaller the angle difference, the higher the satisfaction score. The closer to 1, the higher the weighting coefficient. This reflects the importance contribution of different dimensions to the overall matching credibility. In this embodiment, the weight coefficient of the location mapping dimension... =0.4, this is the most crucial matching criterion, with the highest weighting coefficient, the timestamp dimension. 0.3, this is a secondary factor; time differences affect the weighting, and the weighting coefficient for the speed dimension is also important. =0.2, this is a secondary criterion, an auxiliary position matching factor, and a weighting coefficient for the heading angle dimension. =0.1, this is supplementary verification, auxiliary position matching, and by substituting the satisfaction and weight coefficients of the above four dimensions into the function expression of the confidence score, the confidence score calculation formula of this embodiment is obtained as follows:
[0035] This embodiment uses weighted product instead of simple weighted summation, and its core advantage lies in reflecting the weakest link effect: as long as one dimension is satisfied... A lower score, such as close to 0, indicates a lower final confidence score. This mechanism significantly reduces the likelihood of errors. It rigorously selects high-quality matching data that performs well across all dimensions, including position, heading, speed, and time, while eliminating data that only performs well in some dimensions but has obvious defects. Furthermore, if the confidence level falls below a preset minimum confidence threshold, such as 0.5, the corrected data is discarded and does not participate in model updates. This ensures that data with good matching across all dimensions dominates model optimization, thereby improving the accuracy of subsequent dynamic corrections.
[0036] Example 3: This embodiment, based on Embodiment 1, provides a detailed explanation of the processing logic for the correction data. After acquiring the correction data, to reduce the interference of abnormal data with model updates, this embodiment cleans the correction data and updates the mapping model based on the cleaned correction data meeting the trigger conditions. Specifically, although the correction data has undergone matching and filtering, it may still contain noise points caused by AIS signal drift, multipath effects, or video detection jitter. Directly using this data may lead to deviations in the solution of model parameters. Therefore, before triggering the model update, the system introduces a data cleaning mechanism, which mainly includes two aspects: displacement filtering based on motion trajectory and subject cluster identification based on clustering.
[0037] First, the system executes step S301: Based on the motion trajectory of the moving target, it filters correction data whose displacement between adjacent correction data satisfies the theoretical displacement threshold, which is determined based on the moving target's velocity. Specifically, the motion of a moving target, such as a ship on the water surface, has continuity and physical constraints; its position change between adjacent moments should conform to kinematic laws. The system calculates the actual displacement between two adjacent frames of correction data corresponding to the same target ID and combines this with the target's AIS speed data to calculate the theoretical displacement threshold. For example, if a ship's AIS speed is 10 knots (approximately 5.14 meters per second) and the time interval between adjacent correction data is 5 seconds, then the ship's theoretical maximum movement distance is approximately 25.7 meters. If the actual displacement exceeds a preset multiple of the theoretical displacement threshold, such as 2 or 3 times, the data point is determined to be a trajectory jump point, and the system removes it. This kinematic constraint-based filtering method can eliminate transient anomalies caused by signal jumps, ensuring the continuity and rationality of the correction data in the time dimension.
[0038] Secondly, the system executes step S302: identifying the main clusters from the correction data through cluster analysis and filtering the correction data within these main clusters. Specifically, within the monitoring field of view, legitimate ship movement trajectories typically cluster within specific waterways, while anomalous data often exhibits a discrete distribution. The system employs clustering algorithms, such as the DBSCAN density clustering algorithm, to perform cluster analysis on the pixel coordinate distribution of all correction data. The system identifies the main cluster containing the most data points, which usually corresponds to the main navigable waters; while isolated points far from the main clusters, or secondary clusters containing only a few data points, often correspond to anomalous areas caused by mismatches or signal interference. The system retains the correction data within the main clusters and removes isolated points and secondary cluster data. It should be understood that the parameters of the cluster analysis, such as the neighborhood radius and minimum number of points, can be adaptively adjusted according to the characteristics of the waterways in the monitoring scenario. Through cluster cleaning, the system can further purify the dataset, remove spatially outliers and noise, and ensure that the data participating in model updates originates from real navigable areas.
[0039] After data cleaning, the system executes step S303: determining whether the cleaned correction data meets the triggering conditions. The triggering conditions include the cumulative number of correction data reaching a preset threshold and the distribution coverage of the correction data within a preset area reaching a preset coverage threshold. Specifically, this embodiment sets dual judgment criteria to avoid frequent model updates or overfitting due to localized data. The preset threshold refers to the cumulative number of effective correction data after cleaning reaching a certain amount, such as 50 or 100. This condition ensures that model updates have sufficient sample statistics, reducing the impact of random errors. The preset coverage threshold refers to the spatial distribution coverage of correction data within a preset area, such as the river surface area of the monitoring screen, reaching a certain standard. The system divides the monitoring screen into several grids and counts the proportion of grids containing correction data to the total number of grids. Only when the correction data is spatially evenly distributed, covering the main area of the screen, rather than being concentrated in a local corner, is the coverage requirement deemed met. This dual triggering mechanism ensures that model updates not only rely on sufficient data volume but also on the broad representativeness of the data, thereby guaranteeing the correction accuracy and robustness of the mapping model across the entire field of view.
[0040] Through the synergistic effect of data cleaning and triggering conditions, this embodiment constructs a highly robust model update mechanism. Data cleaning ensures the quality of the input data, eliminating physically unreasonable and spatially discrete noise; triggering conditions ensure that the model update is timely, avoiding model oscillations caused by insufficient or unevenly distributed data. This mechanism enables the mapping model to stably approximate the real scene, improving the reliability of the dynamic correction system.
[0041] In another implementation of this embodiment, when the confidence score screening during the matching process can guarantee data quality, the update module may not need to clean the correction data. Instead, it can directly count the cumulative number and spatial distribution coverage of the original correction data. When the cumulative number of the original correction data reaches a preset number threshold and the distribution coverage reaches a preset coverage threshold, the model update is triggered. For example, if the confidence threshold is set high, such as above 0.8, only data with excellent matching across all dimensions is retained. When the monitoring environment is relatively stable and the signal quality of the external identification system is good, the proportion of outliers in the correction data is low. In this case, additional data cleaning steps are not necessary. In this situation, the system directly counts the cumulative number and spatial distribution coverage of the original correction data. When the cumulative number of the correction data reaches a preset number threshold and the distribution coverage of the correction data within a preset area reaches a preset coverage threshold, the mapping model update is triggered. This reduces the problem of insufficient usable samples due to erroneous data removal during the cleaning process, while also reducing computational overhead and improving the response speed of the model update.
[0042] Example 4:
[0043] This embodiment, based on Embodiment 1, provides a detailed explanation of the update mechanism of the mapping model and the specific mathematical principles of coordinate transformation. When the cleaned correction data meets the triggering conditions, the system executes step S400: updating the mapping model between image coordinates and baseline geographic coordinates based on the correction data and confidence scores. Specifically, the update of the mapping model is essentially a parameter optimization process, the core of which lies in how to use limited and potentially noisy correction data to solve for the mapping parameters that best match the geometric relationships of the real scene.
[0044] During the update of the mapping model, the system first executes sub-step S401: constructing an error function based on the calibration data and confidence scores. The expression for the error function is: in, The longitude prediction value is obtained by image coordinate mapping. The latitude prediction value is obtained by image coordinate mapping. Let be the longitude corresponding to the reference geographic coordinates matched for the i-th correction data. Let be the latitude corresponding to the baseline geographic coordinates matched for the i-th corrected data. Let be the confidence score for the i-th corrected data point. Specifically, this error function measures the model's bias by calculating the sum of squared Euclidean distances between the model-predicted latitude and longitude and the actual latitude and longitude provided by AIS. Unlike traditional least squares methods, this embodiment introduces a confidence score into the error function. As a weighting coefficient, the mechanism of this design is as follows: high confidence scores in calibration data indicate that they are consistent with the external reference altitude in multiple dimensions such as position, heading, and speed, and are high-quality samples that should dominate the calibration process; while low confidence scores may contain some matching errors, and by reducing their weight, the interference of noisy data on model parameters can be suppressed. The system solves for the model parameter θ' that minimizes the error by minimizing the error function E(θ), thereby achieving accurate updates to the mapping model. The solution process can employ nonlinear optimization algorithms such as gradient descent, Gauss-Newton method, or Levenberg-Marquardt method, and this embodiment does not impose any restrictions on this.
[0045] After obtaining the updated model parameters, the system executes sub-step S402: Based on the updated mapping model, the correction data is solved to obtain the updated homography matrix. Specifically, the core parameters of the mapping model can be represented as a 3×3 homography matrix. Since the Earth's surface is curved, while a video image is flat, directly mapping latitude and longitude to pixel coordinates introduces significant nonlinear errors. Therefore, this embodiment employs a transformation path of geographic coordinates - planar coordinates - image coordinates. The homography matrix H describes the perspective transformation relationship between planar coordinates and image coordinates.
[0046] Based on the homography matrix, the system implements a two-way transformation between image coordinates and real geographic location coordinates. The two-way transformation includes forward mapping and inverse mapping. Forward mapping converts the reference geographic coordinates into planar coordinates and then maps them back to image coordinates using the homography matrix. The calculation process is as follows: First, the reference geographic latitude and longitude provided by AIS (… , Convert to planar coordinates using Mercator projection or UTM projection. , Then, using the homography matrix... The transformation is performed, and the formula is: ;
[0047] in, and The predicted horizontal and vertical coordinates of the image. is the homogeneous coordinate scaling factor. The actual calculation formula after expansion is: ; ; in, to Homography matrix The element coefficients. Forward mapping is mainly used in the matching stage, that is, predicting the position where the AIS target should appear in the video frame so as to associate it with the visually detected target.
[0048] Inverse mapping is used to convert image coordinates into planar coordinates using the inverse of the homography matrix, and then into corrected geographic coordinates. The calculation process is as follows: First, the inverse of the homography matrix H^(-1) is used to convert the ship pixel coordinates detected in the video... , Mapped to planar coordinates ( , The formula is: ; The actual calculation formula after expansion is as follows: ; ; in, 1~ Inverse matrix Element coefficients, is the non-zero scale factor of the inverse mapping. Then, the planar coordinates ( , ) Convert back to geographic latitude and longitude through reverse projection ( , The final positioning result of the ship is output as the initial position. Inverse mapping is mainly used in the final position output stage, converting the pixel coordinates detected in the video into geographic latitude and longitude that the user can understand. Through the above-mentioned bidirectional mapping mechanism of forward and reverse directions, this embodiment constructs a complete coordinate transformation closed loop, ensuring both the accuracy of the matching process and the real-time output of the positioning result, demonstrating the algorithm's high executability and practical value.
[0049] Example 5: This embodiment provides a dynamic correction system for geographic coordinates. The system is used to implement the dynamic correction method for geographic coordinates described in any one of embodiments 1 to 4 above. The correction system includes an acquisition module, a matching module, and an update module. The acquisition module is used to acquire the image coordinates of a moving target and the reference geographic coordinates output by an external recognition system. The matching module is configured to match the image coordinates and the reference geographic coordinates based on a matching dimension to determine the confidence score and correction data. The update module is configured to update the mapping model between the image coordinates and the reference geographic coordinates based on the correction data and the confidence score when the correction data meets the triggering conditions, and convert the image coordinates into corrected geographic coordinates for output.
[0050] Specifically, the acquisition module is the system's data entry point, responsible for collecting raw, multi-source heterogeneous data. In this embodiment, the acquisition module includes a video acquisition device and an external identification system receiving unit. The video acquisition device is preferably a high-definition surveillance camera deployed on a shore-based or platform-based facility, used to collect video images of the monitored waterway in real time. The video acquisition device is connected to a video processing unit, which internally runs target detection and tracking algorithms to identify moving targets, such as ships, from the video stream and extract their pixel coordinates in the image, i.e., image coordinates. The external identification system receiving unit is preferably an AIS receiver, used to receive message data broadcast by the Automatic Identification System (AIS) and parse the ship's unique identification code (MMSI), latitude and longitude, heading, speed, and other dynamic information from the message, where latitude and longitude serve as the reference geographic coordinates. It should be understood that the acquisition module is not limited to the above hardware combination. In other embodiments, the video acquisition device can also be an infrared thermal imager or a radar video fusion device, and the external identification system can also be a BeiDou / GPS positioning terminal or a radar tracking system, as long as it can provide image coordinates and high-precision reference geographic coordinates. The acquisition module timestamps the extracted image coordinates and baseline geographic coordinates and sends them to the matching module in real time.
[0051] The matching module is the core processing unit of the system, and its hardware carrier can be an industrial control computer, an embedded processor, or a cloud server. The matching module is configured with a data association algorithm to execute the matching logic described in Embodiment 2 above. Specifically, the matching module receives image coordinates and reference geographic coordinates sent by the acquisition module, first performs time alignment and identity association, and then performs a joint judgment based on multiple matching dimensions such as position mapping, heading angle, speed, and timestamp. The matching module internally stores the current mapping model parameters, enabling it to positively map the reference geographic coordinates to the predicted image coordinates, and then calculate the deviation, such as the Euclidean distance, between the predicted and actual image coordinates. The matching module calculates a confidence score based on the satisfaction level of each dimension and selects high-quality data pairs with confidence scores reaching a preset threshold as correction data. These correction data are temporarily stored in the system's storage unit, awaiting subsequent processing. Through the refined processing of the matching module, mismatches and low-quality data are eliminated, ensuring the reliability of the correction data source.
[0052] The update module is the system's decision-making and evolution unit, and its hardware can also be the processor described above. The update module is equipped with a model optimization algorithm to execute the data cleaning, trigger determination, and model update logic described in Embodiments 3 and 4. Specifically, the update module periodically or under the trigger of a specific event reads the correction data from the storage unit. First, the update module executes a data cleaning procedure to remove trajectory jumps and spatially isolated points. Then, the update module counts the cumulative quantity and spatial distribution coverage of the cleaned correction data to determine if the trigger condition is met. When the trigger condition is met, the update module constructs a weighted error function based on the correction data and confidence scores, and solves for the updated homography matrix parameters using a nonlinear optimization algorithm (such as the Gauss-Newton method), thereby completing the update of the mapping model. The updated model parameters are written back to the storage unit, overwriting the old parameters, for use by the matching module and the output module. The update module is also responsible for converting the real-time detected image coordinates into corrected geographic coordinates through inverse mapping and outputting them to the display terminal or the backend management system.
[0053] Through the collaborative work of the acquisition module, matching module, and update module described above, this embodiment constructs a closed-loop dynamic correction system. The acquisition module continuously provides multi-source data, the matching module filters out high-quality correction samples, and the update module uses these samples to drive the continuous evolution of the model. This hardware-software integrated system architecture embeds complex algorithmic logic into the hardware device, realizing the automation, intelligence, and high precision of ship target positioning in maritime video surveillance scenarios, and significantly reducing the operation and maintenance costs of manual on-site calibration.
[0054] Example 6: This embodiment uses a ship positioning application in a maritime video surveillance scenario as an example to explain in detail the dynamic correction method for the aforementioned geographic coordinates. In this scenario, surveillance cameras are typically deployed at high locations such as shore-based structures, lighthouses, or offshore platforms. Due to environmental factors such as tidal fluctuations, strong winds, or ground subsidence, the physical orientation of the cameras is prone to slight changes, causing the initially calibrated mapping model to gradually become invalid. This embodiment introduces the Automatic Identification System (AIS) as an external identification system and constructs a closed-loop feedback mechanism to achieve dynamic correction of the mapping model.
[0055] Specifically, in step S100, the acquisition module acquires real-time video streams of the monitored waterway using a high-definition camera and utilizes target detection algorithms in the video processing unit, such as the YOLO series or background subtraction method, to identify ship targets in the image and extract the pixel coordinates of the ships as image coordinates. Simultaneously, the AIS receiving unit continuously receives AIS message data broadcast by surrounding ships, parsing out information such as the ship's unique identification code (MMSI), latitude and longitude, heading, and speed, with the latitude and longitude serving as the reference geographic coordinates. Since AIS data and video data may be out of sync in time, the system needs to align their timestamps to ensure consistency of the matched data in the temporal dimension.
[0056] In step S200, the matching module executes multi-dimensional matching logic. The system forward maps the baseline geographic coordinates provided by AIS to predicted image coordinates using the current mapping model and compares them with the actual image coordinates detected by the video. For example, the predicted position of a ship mapped from its AIS coordinates to the image is [predicted position], while the actual position detected by the video is [actual position]. The Euclidean distance between the two is 30 pixels, which is less than the preset distance threshold of 50 pixels, satisfying the position consistency requirement. Simultaneously, the system extracts the major axis direction of the ship's outline in the video as the visual heading angle and compares it with the heading angle in the AIS message. The difference is within a preset range, satisfying the heading consistency requirement. Through joint judgment of multiple dimensions such as position, heading, speed, and time, the system calculates the confidence score of the matching data. If the confidence score is higher than a preset threshold, such as 0.8, it is stored in the database as valid correction data.
[0057] In step S300, the update module cleans and triggers judgments on the accumulated correction data. For example, if the system detects an anomaly in the displacement of a vessel between two adjacent frames of correction data, exceeding the theoretical displacement threshold corresponding to its speed, it is identified as a trajectory jump point and removed. Simultaneously, isolated noise points far from the main channel are removed through cluster analysis. When the cumulative number of cleaned valid correction data reaches 100, and the distribution coverage within the river surface area of the monitored image reaches 80%, the model update mechanism is triggered. Based on these high-quality correction data and confidence scores, the system constructs a weighted error function and solves for the updated homography matrix parameters using a nonlinear optimization algorithm.
[0058] In another implementation of this embodiment, when the confidence score screening during the matching process can guarantee data quality, the update module may not need to clean the correction data. Instead, it can directly count the cumulative quantity and spatial distribution coverage of the original correction data. When the cumulative quantity of the original correction data reaches a preset quantity threshold and the distribution coverage reaches a preset coverage threshold, the model update is triggered. This simplified approach is particularly suitable in the early stages of data accumulation, avoiding the problem of insufficient usable samples due to accidental data removal during the cleaning process. It also reduces computational overhead and improves the response speed of the model update.
[0059] The technical effectiveness of this embodiment has been verified in on-site maritime measurements. At a port monitoring point, seasonal tidal changes caused a water level difference of up to 3 meters, and the camera mounting bracket experienced a slight displacement of approximately 0.5 degrees due to wind. If traditional static calibration methods were used, the ship positioning deviation would accumulate over time, with a maximum deviation exceeding 50 meters, severely impacting monitoring safety. After applying the dynamic correction method described in this embodiment, the system automatically collected approximately 200 sets of valid correction data within 24 hours of operation and triggered three model updates. Measured data showed that the corrected ship positioning deviation stabilized within 5 meters, improving positioning accuracy by over 90%. This result demonstrates that the present invention can solve the mapping deviation problem caused by environmental changes, achieving a shift from "manual periodic calibration" to "automatic real-time evolution," reducing maintenance costs, and improving the reliability and practicality of the maritime monitoring system.
[0060] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0061] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method of dynamic correction of geographic coordinates, characterized in that, The correction method includes the following steps: Obtain the image coordinates of the moving target and the reference geographic coordinates output by the external recognition system; The image coordinates are matched with the reference geographic coordinates to determine a confidence score, and correction data that reaches a preset threshold are filtered based on the confidence score; and When the correction data meets the triggering condition, the mapping model between the image coordinates and the reference geographic coordinates is updated based on the correction data and the confidence score, and the image coordinates are converted into corrected geographic coordinates for output.
2. The method of dynamic revision of geographical coordinates according to claim 1, characterized in that, The image coordinates are matched with the reference geographic coordinates based on multiple matching dimensions. When the image coordinates and the reference geographic coordinates are consistent in all matching dimensions, a correspondence between the image coordinates and the corresponding reference geographic coordinates is established.
3. The method of dynamic revision of geographical coordinates according to claim 2, characterized in that, The confidence score is determined by a weighted product operation based on the satisfaction level of the matching dimension and the corresponding weight coefficient. Correction data when the confidence score reaches a preset threshold is used to update the mapping model. The functional expression for the confidence score is: ; wherein, is the confidence score , is the satisfaction of the mth matching dimension, is the weight coefficient of the mth matching dimension, is the number of matching dimensions.
4. The dynamic correction method for geographic coordinates according to claim 3, characterized in that, The triggering conditions include the cumulative number of the correction data reaching a preset number threshold, and the distribution coverage of the correction data within a preset area reaching a preset coverage threshold.
5. The dynamic correction method for geographic coordinates according to claim 3, characterized in that, Updating the mapping model includes the following steps: An error function is constructed based on the correction data and the confidence score. An updated mapping model is then determined based on the error function. The expression for the error function is: ; in, The longitude is obtained by mapping image coordinates. Latitude obtained from image coordinate mapping The longitude corresponding to the reference geographic coordinates matched for the i-th correction data. The latitude corresponding to the reference geographic coordinates matched for the i-th correction data.
6. The method for dynamically correcting geographic coordinates according to claim 5, characterized in that, The updated mapping model is used to solve the correction data to obtain the updated homography matrix. Based on the homography matrix, a bidirectional transformation is performed between the image coordinates and the real geographic location coordinates. The bidirectional transformation includes forward mapping and inverse mapping. The forward mapping is used to convert the reference geographic coordinates into planar coordinates and then map them into image coordinates through the homography matrix. The inverse mapping is used to convert the image coordinates into planar coordinates through the inverse of the homography matrix and then convert them into corrected geographic coordinates.
7. The method for dynamically correcting geographic coordinates according to claim 1, characterized in that, The correction data is cleaned, and the mapping model is updated when the cleaned correction data meets the triggering condition.
8. The method for dynamically correcting geographic coordinates according to claim 7, characterized in that, The cleaning process includes the following steps: Based on the motion trajectory of the moving target, correction data that satisfy the theoretical displacement threshold between adjacent correction data are selected, and the theoretical displacement threshold is determined based on the motion speed of the moving target. The main clusters are identified from the calibration data through cluster analysis, and the calibration data of the main clusters are then filtered.
9. The method for dynamically correcting geographic coordinates according to claim 2, characterized in that, The external identification system is the Automatic Identification System (AIS), and the reference geographic coordinates are extracted from the AIS message data.
10. A dynamic correction system for geographic coordinates, characterized in that, The correction system includes: The acquisition module acquires the image coordinates of the moving target and the reference geographic coordinates output by the external recognition system; The matching module is configured to match the image coordinates with the reference geographic coordinates based on a matching dimension to determine the confidence score and correction data; and The update module is configured to update the mapping model between the image coordinates and the reference geographic coordinates based on the correction data and the confidence score when the correction data meets the triggering conditions, and then convert the image coordinates into corrected geographic coordinates for output.