River basin data processing method, device, equipment, medium and program product

By performing dimensionality reduction, spatiotemporal analysis, and hash encryption on river basin data, generating hash chain values ​​and uploading them to the blockchain, the security issues of centralized storage are resolved and efficient and secure data storage is achieved.

CN119760741BActive Publication Date: 2025-09-19CHINA THREE GORGES CORPORATION
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411821682.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-11
Publication Date
2025-09-19
Estimated Expiration
2044-12-11

AI Technical Summary

Technical Problem

In existing technologies, river basin data is stored in centralized servers, which poses a risk of tampering, leakage or loss and has low security.

Method used

By performing dimensionality reduction, spatiotemporal analysis, and hash encryption on river basin data, a hash chain value is generated and asymmetric encryption is performed. Finally, the signature value is uploaded to the blockchain to ensure the integrity and security of the data.

Benefits of technology

It improves the security and reliability of data storage in river basins, reduces the risk of data tampering, and improves the efficiency and trust of data storage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119760741B_ABST
    Figure CN119760741B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of data processing technology, and discloses a method, device, equipment, medium and program product for processing river basin data. The method for processing river basin data includes: extracting a first data element value from an acquired historical original data matrix, performing dimensionality reduction processing on the first data element value to obtain a second data element value; performing spatiotemporal analysis on the second data element value to obtain a third data element value, and predicting the data element value for a preset time period based on the third data element value to obtain a data element prediction value; performing hash processing on the third data element value and the data element prediction value to obtain a first hash chain value and a second hash chain value; performing encryption processing on the first hash chain value and the second hash chain value to obtain a first signature value and a second signature value; and uploading the first signature value and the second signature value to a blockchain. The present invention processes river basin data and uploads it to a blockchain, thereby improving the security of river basin data storage.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a method, device, equipment, medium and program product for processing river basin data. Background Art

[0002] River basin data plays an important role in ecological protection, water resources management, and climate change research. Taking the hydrological data and climate data of the Yangtze River basin as an example, they can be used for early warning and prevention of natural disasters, and can also be used for the management and allocation of water resources in the Yangtze River basin. Therefore, it is also important to record and protect natural environment data.

[0003] In related technologies, the method for storing river basin data is to store the river basin data in a database. This storage method relies on a centralized server or server cluster. Once the central node is attacked, invaded by a virus, or the hardware fails, the data will face the risk of being tampered with, leaked, or lost. Therefore, this storage method has low security. Summary of the Invention

[0004] In view of this, the present invention provides a method, apparatus, device, medium and program product for processing river basin data to solve the problem of low security of river basin data storage.

[0005] In a first aspect, the present invention provides a method for processing river basin data, including: obtaining a historical original data matrix corresponding to the river basin data, extracting a first data element value in the historical original data matrix, and performing dimensionality reduction processing on the first data element value to obtain a second data element value; performing spatiotemporal analysis on the second data element value to obtain a third data element value under multiple spatial coordinates, and predicting a data element value for a preset time period based on the third data element value to obtain a data element prediction value; performing hash processing on the third data element value to obtain a first hash chain value; performing hash processing on the data element prediction value to obtain a second hash chain value; performing encrypting processing on the first hash chain value to obtain a first signature value; performing encrypting processing on the second hash chain value to obtain a second signature value; and uploading the first signature value and the second signature value to a blockchain.

[0006] The present invention first extracts the historical original data matrix corresponding to the acquired river basin data to obtain a first data element value, which helps to convert the river basin data into a unified standard and improve data quality. The first element value is subjected to dimensionality reduction processing to obtain a second data element value. The dimensionality reduction processing retains the key features in the first element value, reduces the amount of data, and helps to improve the efficiency of subsequent blockchain uploads. The second data element value is subjected to spatiotemporal analysis to obtain a third data element value under multiple spatial coordinates, captures the dynamic changes of the second data element value under different time and space coordinates, and predicts the data element value of a preset time period based on the third data element value to obtain a data element prediction value. The interaction between time and space is comprehensively considered to improve the accuracy of the data element prediction value. The present invention performs hash processing on the third data element value to obtain a first hash chain value, performs hash processing on the data element prediction value to obtain a second hash chain value, encrypts the first hash chain value to obtain a first signature value, encrypts the second hash chain value to obtain a second signature value, and uploads the first signature value and the second signature value to the blockchain. Compared with the related art, the present invention reduces the amount of river basin data and improves the efficiency of river basin data storage by standardizing and streamlining river basin data. The chain structure of the hash chain value ensures the integrity and security of the data, encrypts the hash chain value to improve the security of data storage, and uploads the first signature value and the second signature value to the blockchain to prevent the river basin data from being tampered with and enhance the trustworthiness of the river basin data. Therefore, the present invention improves the security and reliability of river basin data storage.

[0007] In an optional embodiment, extracting the first data element value from the historical original data matrix includes: extracting the historical original data matrix using a preprocessing function to obtain the first data element value; wherein the expression of the preprocessing function is:

[0008]

[0009] in, is the value of the first data element in the i-th row and j-th column of the historical original data matrix after processing, X ij is the data element value of the i-th row and j-th column in the historical original data matrix, X j is the data element value of the jth column in the historical original data matrix, max is the maximum value, min is the minimum value, cos is the cosine function, and log is the logarithmic function.

[0010] In the preprocessing function of the present invention, the cosine function smoothing processing helps to reduce outliers caused by sudden weather or data collection errors, improve the quality of the first data element value, and through logarithmic transformation, make the influence of small values ​​on the results more obvious, thereby maintaining sensitivity when processing the historical original data matrix and adapting to the impact of small-scale changes.

[0011] In an optional embodiment, performing dimensionality reduction processing on the first data element value to obtain the second data element value includes: performing dimensionality reduction processing on the first data element value using a preset dimensionality reduction model to obtain the second data element value; wherein the expression of the preset dimensionality reduction model is:

[0012]

[0013] Among them, Y i is the value of the second data element after the i-th dimension reduction, tanh is the hyperbolic tangent function, n is the number of hyperbolic tangent function terms, γ j is the first adjustment factor of the j-th hyperbolic tangent function term, β j is the second adjustment factor of the j-th hyperbolic tangent function term, δ j is the third adjustment factor of the jth hyperbolic tangent function term, sin is the sine function, n is the number of sine function terms, η k is the fourth adjustment factor of the kth sine function term, φ k is the fifth adjustment factor of the kth sine function term, ψ k is the sixth adjustment factor of the kth sine function term, ξ l is the seventh adjustment factor of the lth exponential function term, p is the number of exponential function terms, θ l is the eighth adjustment factor of the lth exponential function term, is the first data element value.

[0014] The present invention captures the complex nonlinear relationship between the values ​​of the first data elements through nonlinear functions, namely the hyperbolic tangent function and the sine function, retains key features, significantly reduces the amount of data after dimensionality reduction, and makes subsequent analysis and calculation more efficient.

[0015] In an optional embodiment, performing a spatiotemporal analysis on the second data element value to obtain a third data element value at a plurality of spatial coordinates includes: performing a spatiotemporal analysis on the second data element value according to a preset spatiotemporal analysis function to obtain the third data element value at a plurality of spatial coordinates; wherein the expression of the preset spatiotemporal analysis function is:

[0016]

[0017] Where S(t,x,y) is the value of the third data element at the spatial coordinate (x,y) at time t, p′ is the maximum power of the time t, q′ is the maximum power of the data element value x′, r′ is the maximum power of the data element value y′, and α i′j′k′ is the weight when the power is i′, j′ and k′, t i′ is the i′th power of time t, x ′j′ is the j′th power of the data element value x′ with the horizontal coordinate x in the second data element value after dimensionality reduction, y ′k′ is the k′th power of the data element value y′ with the ordinate y in the second data element value after dimensionality reduction, sin is the sine function, cos is the cosine function, s′ is the number of exponential functions and cosine functions, β l′ is the ninth adjustment factor of the l′th exponential function term, λ l′ is the time-wise adjustment factor of the l′th exponential function term, ω l′ is the eleventh adjustment factor of the l′th cosine function term, θ l′ is the twelfth adjustment factor of the l′th cosine function term, u′ is the number of sine function terms, γ m′ is the thirteenth adjustment factor of the m′th sine function term, μ m′ is the fourteenth adjustment factor of the m′th sine function term, v m′ is the fifteenth adjustment factor of the m′th sine function term, ρ m′ is the sixteenth adjustment factor of the m′th sine function term.

[0018] This method uses preset spatiotemporal analysis functions to capture the changes in different indicators in river basin data over time and space. Combining high-order polynomials and periodic functions effectively simulates the complex impacts of different dynamic factors on river basin data. Through continuous spatiotemporal analysis, ecological changes can be reflected in a timely manner.

[0019] In an optional embodiment, predicting a data element value for a preset time period based on a third data element value to obtain a data element predicted value includes: inputting the third data element value into a data element prediction model to obtain the data element predicted value; the input of the data element prediction model is the third data element value, the output of the data element prediction model is the data element predicted value, and the expression of the data element prediction model is:

[0020]

[0021] in, is the predicted value of the data element at time t, u″ is the number of spatiotemporal analysis function terms, λ m″ is the weight of the m″th spatiotemporal analysis function term, S m″is the third data element value corresponding to the m″th spatiotemporal analysis function term, sin is the sine function, cos is the cosine function, w″ is the number of cosine function terms, μ v″ is the seventeenth adjustment factor of the v″th cosine function term, v v″ is the eighteenth adjustment factor of the v″th cosine function term, ζ v″ is the nineteenth adjustment factor of the v″th cosine function term, z″ is the number of sine function terms, κ n″ is the twentieth adjustment factor of the n″th sine function term, η n″ is the twenty-first adjustment factor of the n″th sine function term, θ n″ is the twenty-second adjustment factor of the n″th sine function term.

[0022] The present invention takes into account time, space and their interactions by combining the results of spatiotemporal analysis, thereby enhancing the adaptability to complex environmental factors and improving the reliability and accuracy of predictions.

[0023] In an optional implementation, encrypting the first Hash chain value to obtain a first signature value; encrypting the second Hash chain value to obtain a second signature value includes: encrypting the first Hash chain value using asymmetric encryption to obtain the first signature value; encrypting the second Hash chain value using asymmetric encryption to obtain the second signature value.

[0024] In a second aspect, the present invention provides a device for processing river basin data, comprising: a data preprocessing module for obtaining a historical original data matrix of a target area, extracting a first data element value from the historical original data matrix, and performing dimensionality reduction processing on the first data element value to obtain a second data element value; a data element prediction module for performing spatiotemporal analysis on the second data element value to obtain a third data element value under multiple spatial coordinates, and predicting the data element value of a preset time period based on the third data element value to obtain a data element prediction value; a hash processing module for performing hash processing on the third data element value to obtain a first hash chain value; performing hash processing on the data element prediction value to obtain a second hash chain value; an encryption processing module for performing encrypting processing on the first hash chain value to obtain a first signature value; performing encrypting processing on the second hash chain value to obtain a second signature value; and a blockchain upload module for uploading the first signature value and the second signature value to the blockchain.

[0025] In a third aspect, the present invention provides a computer device comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the computer instructions to execute the river basin data processing method of the first aspect or any corresponding embodiment thereof.

[0026] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the river basin data processing method of the first aspect or any corresponding embodiment thereof.

[0027] In a fifth aspect, the present invention provides a computer program product comprising computer instructions for causing a computer to execute the method for processing river basin data according to the first aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in related technologies, the following briefly introduces the drawings required for use in the specific embodiments or related technical descriptions. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0029] Figure 1 is a flow chart of a method for processing river basin data according to an embodiment of the present invention;

[0030] Figure 2 is a flow chart of another method for processing river basin data according to an embodiment of the present invention;

[0031] Figure 3 is a structural block diagram of a device for processing river basin data according to an embodiment of the present invention;

[0032] Figure 4 Schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0033] To make the purpose, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative efforts shall fall within the scope of protection of the present invention.

[0034] River basin data plays an important role in ecological protection, water resources management, and climate change research. Taking the hydrological data and climate data of the Yangtze River basin as an example, they can be used for early warning and prevention of natural disasters, and can also be used for the management and allocation of water resources in the Yangtze River basin. Therefore, it is also important to record and protect natural environment data.

[0035] Blockchain technology is a decentralized, distributed ledger technology used to securely record and verify transactions or data. Blockchain technology has several key characteristics, including decentralization, immutability, transparency, and security. Decentralization refers to the recording of data on multiple nodes through a distributed network, eliminating the need for specific institutions. Immutability means that once data is recorded on the blockchain, it is virtually impossible to tamper with. Each block contains the hash value of the previous block, forming a chain structure that ensures data integrity and security. Transparency means that data on the blockchain is open and transparent to all users, and any user can view transaction records. Security refers to the use of cryptographic techniques (such as public and private key encryption) by blockchain to ensure the security of data transmission and storage. Each piece of data must be verified by multiple nodes to prevent fraud and tampering. Therefore, using blockchain technology to process data in the Yangtze River Basin has many advantages.

[0036] In related technologies, the method for storing river basin data is to store the river basin data in a database. This storage method relies on a centralized server or server cluster. Once the central node is attacked, invaded by a virus, or the hardware fails, the data will face the risk of being tampered with, leaked, or lost. Therefore, this storage method has low security.

[0037] An embodiment of the present invention provides a method for processing river basin data, which improves the security of river basin data storage by processing the river basin data and uploading it to the blockchain.

[0038] According to an embodiment of the present invention, an embodiment of a method for processing river basin data is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0039] In this embodiment, a method for processing river basin data is provided, which can be used in computer equipment. Figure 1 FIG. 1 is a flow chart of a method for processing river basin data according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0040] Step S101: obtain the historical original data matrix corresponding to the river basin data, extract the first data element value in the historical original data matrix, and perform dimensionality reduction processing on the first data element value to obtain the second data element value.

[0041] Among them, the river basin data includes basic geographic information data, hydrological data, and ecological data of the river basin. For example, the river basin data can be the Yangtze River Basin data; the historical original data matrix is ​​a matrix in which various data indicators of the river basin are arranged in a certain order and rules; the first data element value is the specific numerical value corresponding to each data element or indicator in the historical original data matrix.

[0042] In some optional implementations, extracting the first data element value from the historical original data matrix includes: extracting the historical original data matrix using a preprocessing function to obtain the first data element value; wherein the expression of the preprocessing function is:

[0043]

[0044] in, is the value of the first data element in the i-th row and j-th column of the historical original data matrix after processing, X ij is the data element value of the i-th row and j-th column in the historical original data matrix, X j is the data element value of the jth column in the historical original data matrix, max is the maximum value, min is the minimum value, cos is the cosine function, and log is the logarithmic function.

[0045] In the preprocessing function of the embodiment of the present invention, the cosine function smoothing processing helps to reduce outliers caused by sudden weather or data collection errors, improve the quality of the first data element value, and through logarithmic transformation, make the impact of small values ​​on the results more obvious, thereby maintaining sensitivity when processing the historical original data matrix and adapting to the impact of small-scale changes.

[0046] In some optional implementations, performing dimensionality reduction processing on the first data element value to obtain the second data element value includes: performing dimensionality reduction processing on the first data element value using a preset dimensionality reduction model to obtain the second data element value; wherein the expression of the preset dimensionality reduction model is:

[0047]

[0048] Among them, Y i is the value of the second data element after the i-th dimension reduction, tanh is the hyperbolic tangent function, n is the number of hyperbolic tangent function terms, γ j is the first adjustment factor of the j-th hyperbolic tangent function term, β j is the second adjustment factor of the j-th hyperbolic tangent function term, δ j is the third adjustment factor of the jth hyperbolic tangent function term, sin is the sine function, m is the number of sine function terms, η k is the fourth adjustment factor of the kth sine function term, φ kis the fifth adjustment factor of the kth sine function term, ψ k is the sixth adjustment factor of the kth sine function term, ξ l is the seventh adjustment factor of the lth exponential function term, p is the number of exponential function terms, θ l is the eighth adjustment factor of the lth exponential function term, is the first data element value.

[0049] The embodiment of the present invention captures the complex nonlinear relationship between the values ​​of the first data elements through nonlinear functions, namely the hyperbolic tangent function and the sine function, retains key features, significantly reduces the amount of data after dimensionality reduction, and makes subsequent analysis and calculation more efficient.

[0050] Step S102: Perform spatiotemporal analysis on the second data element value to obtain the third data element value under multiple spatial coordinates, and predict the data element value of a preset time period based on the third data element value to obtain the data element prediction value.

[0051] In some optional embodiments, performing a spatiotemporal analysis on the second data element value to obtain a third data element value at a plurality of spatial coordinates includes: performing a spatiotemporal analysis on the second data element value according to a preset spatiotemporal analysis function to obtain the third data element value at a plurality of spatial coordinates; wherein the expression of the preset spatiotemporal analysis function is:

[0052]

[0053] Where S(t,x,y) is the value of the third data element at the spatial coordinate (x,y) at time t, p′ is the maximum power of the time t, q′ is the maximum power of the data element value x′, r′ is the maximum power of the data element value y′, and α i′j′k′ is the weight when the power is i′, j′ and k′, t i′ is the i′th power of time t, x ′j′ is the j′th power of the data element value x′ with the horizontal coordinate x in the second data element value after dimensionality reduction, y ′k′ is the k′th power of the data element value y′ with the ordinate y in the second data element value after dimensionality reduction, sin is the sine function, cos is the cosine function, s′ is the number of exponential functions and cosine functions, β l′ is the ninth adjustment factor of the l′th exponential function term, λ l′ is the time-wise adjustment factor of the l′th exponential function term, ω l′ is the eleventh adjustment factor of the l′th cosine function term, θ l′ is the twelfth adjustment factor of the l′th cosine function term, u′ is the number of sine function terms, γ m′ is the thirteenth adjustment factor of the m′th sine function term, μm′ is the fourteenth adjustment factor of the m′th sine function term, v m′ is the fifteenth adjustment factor of the m′th sine function term, ρ m′ is the sixteenth adjustment factor of the m′th sine function term.

[0054] In some optional embodiments, predicting a data element value for a preset time period based on a third data element value to obtain a data element predicted value includes: inputting the third data element value into a data element prediction model to obtain the data element predicted value; the input of the data element prediction model is the third data element value, the output of the data element prediction model is the data element predicted value, and the expression of the data element prediction model is:

[0055]

[0056] in, is the predicted value of the data element at time t, u″ is the number of spatiotemporal analysis function terms, λ m″ is the weight of the m″th spatiotemporal analysis function term, S m″ is the third data element value corresponding to the m″th spatiotemporal analysis function term, sin is the sine function, cos is the cosine function, w″ is the number of cosine function terms, μ v″ is the seventeenth adjustment factor of the v″th cosine function term, v v″ is the eighteenth adjustment factor of the v″th cosine function term, ζ v″ is the nineteenth adjustment factor of the v″th cosine function term, z″ is the number of sine function terms, κ n″ is the twentieth adjustment factor of the n″th sine function term, η n″ is the twenty-first adjustment factor of the n″th sine function term, θ n″ is the twenty-second adjustment factor of the n″th sine function term.

[0057] Step S103, performing hash processing on the third data element value to obtain a first hash chain value; performing hash processing on the data element prediction value to obtain a second hash chain value.

[0058] In some optional embodiments, a hash function is used to hash the third data element value and the data element prediction value to obtain a first hash chain value and a second hash chain value. Exemplarily, the hash function can be a cryptographic hash function (Secure Hash Algorithm 1, SHA-1).

[0059] Step S104: encrypt the first Hash chain value to obtain a first signature value; encrypt the second Hash chain value to obtain a second signature value.

[0060] In some optional implementations, encrypting the first Hash chain value to obtain a first signature value; encrypting the second Hash chain value to obtain a second signature value includes: encrypting the first Hash chain value using asymmetric encryption to obtain the first signature value; encrypting the second Hash chain value using asymmetric encryption to obtain the second signature value.

[0061] Exemplarily, the asymmetric encryption method may be a Digital Signature Algorithm (DSA).

[0062] In some optional implementations, the first hash chain value is encrypted using asymmetric encryption to obtain a first signature value; the second hash chain value is encrypted using asymmetric encryption to obtain a second signature value, and the method further includes: encrypting the first hash chain value and the second hash chain value using asymmetric encryption to obtain global parameters, a first signature value, and a second signature value, generating a private key and a public key based on the global parameters, and sending the private key to the user.

[0063] Step S105: Upload the first signature value and the second signature value to the blockchain.

[0064] In some optional embodiments, the method for processing river basin data also includes: receiving an identity authentication instruction initiated by a user, generating challenge information based on the identity authentication instruction, receiving a third signature value obtained by the user signing the challenge information using a private key, and verifying the third signature value using a public key to complete the identity authentication.

[0065] The method for processing river basin data provided in this embodiment first extracts the historical original data matrix corresponding to the acquired river basin data to obtain a first data element value, which helps to convert the river basin data into a unified standard and improve data quality. The first element value is subjected to dimensionality reduction processing to obtain a second data element value. The dimensionality reduction processing retains the key features in the first element value, reduces the amount of data, and helps to improve the efficiency of subsequent blockchain uploads. The second data element value is subjected to spatiotemporal analysis to obtain a third data element value under multiple spatial coordinates, captures the dynamic changes of the second data element value under different time and space coordinates, and predicts the data element value of a preset time period based on the third data element value to obtain a data element prediction value. This comprehensively considers the interaction between time and space and improves the accuracy of the data element prediction value. The embodiment of the present invention performs hash processing on the third data element value to obtain a first hash chain value, performs hash processing on the data element prediction value to obtain a second hash chain value, encrypts the first hash chain value to obtain a first signature value, encrypts the second hash chain value to obtain a second signature value, and uploads the first signature value and the second signature value to the blockchain. Compared with the related art, the embodiment of the present invention reduces the amount of river basin data and improves the efficiency of river basin data storage by standardizing and streamlining river basin data. The chain structure of the hash chain value ensures the integrity and security of the data, encrypts the hash chain value to improve the security of data storage, and uploads the first signature value and the second signature value to the blockchain to prevent the river basin data from being tampered with and enhance the trustworthiness of the river basin data. Therefore, the embodiment of the present invention improves the security and reliability of river basin data storage.

[0066] In this embodiment, a method for processing river basin data is provided, which can be used in computer equipment. Figure 2 FIG. 1 is a flow chart of another method for processing river basin data according to an embodiment of the present invention. Figure 2 As shown, the process includes:

[0067] Obtain the original data matrix of the Yangtze River Basin, set a preprocessing function to preprocess the data elements of the Yangtze River Basin, generate the preprocessed data element values, set a data dimension reduction model, perform dimension reduction processing on the preprocessed data element values, and generate the reduced dimension data element values. For details, please refer to Figure 1 Step S101 of the illustrated embodiment will not be described in detail here.

[0068] Set up a spatiotemporal analysis function to perform spatiotemporal analysis on the data element values ​​after dimensionality reduction to generate the data element values ​​at each spatial coordinate at any time, and set up a data element prediction model to generate the predicted data element values ​​at each spatial coordinate based on the data element values ​​at each spatial coordinate at any time. Figure 1Step S102 of the illustrated embodiment will not be described in detail here.

[0069] The data element value at each spatial coordinate at any time and the predicted data element value at each spatial coordinate are hashed to generate a hash chain value, the hash chain value is signed to generate a signature value, the signature value is uploaded to the blockchain, and identity authentication is performed. For details, please refer to Figure 1 Step S103, step S104 and step S105 of the illustrated embodiment are not described in detail here.

[0070] This embodiment also provides a river basin data processing device for implementing the above-mentioned embodiments and preferred embodiments. Details already described will not be repeated here. As used below, the term "module" may refer to a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation using hardware, or a combination of software and hardware, is also possible and contemplated.

[0071] This embodiment provides a device for processing river basin data, such as Figure 3 Shown, including:

[0072] The data preprocessing module 301 is used to obtain the historical original data matrix of the target area, extract the first data element value in the historical original data matrix, and perform dimensionality reduction processing on the first data element value to obtain the second data element value.

[0073] The data element prediction module 302 is used to perform spatiotemporal analysis on the second data element value to obtain the third data element value under multiple spatial coordinates, and to predict the data element value of a preset time period based on the third data element value to obtain the data element prediction value.

[0074] The hash processing module 303 is used to perform hash processing on the third data element value to obtain a first hash chain value; and to perform hash processing on the data element prediction value to obtain a second hash chain value.

[0075] The encryption processing module 304 is configured to encrypt the first Hash chain value to obtain a first signature value; and encrypt the second Hash chain value to obtain a second signature value.

[0076] The blockchain uploading module 305 is used to upload the first signature value and the second signature value to the blockchain.

[0077] In an optional embodiment, the data preprocessing module 301 includes:

[0078] The preprocessing unit is used to extract the historical original data matrix using a preprocessing function to obtain a first data element value; wherein the expression of the preprocessing function is:

[0079]

[0080] in, is the value of the first data element in the i-th row and j-th column of the historical original data matrix after processing, X ij is the data element value of the i-th row and j-th column in the historical original data matrix, X j is the data element value of the jth column in the historical original data matrix, max is the maximum value, min is the minimum value, cos is the cosine function, and log is the logarithmic function.

[0081] In an optional embodiment, the data preprocessing module 301 includes:

[0082] A dimensionality reduction processing unit is used to perform dimensionality reduction processing on the first data element value using a preset dimensionality reduction model to obtain a second data element value; wherein the expression of the preset dimensionality reduction model is:

[0083]

[0084] Among them, Y i is the value of the second data element after the i-th dimension reduction, tanh is the hyperbolic tangent function, n is the number of hyperbolic tangent function terms, γ j is the first adjustment factor of the j-th hyperbolic tangent function term, β j is the second adjustment factor of the j-th hyperbolic tangent function term, δ j is the third adjustment factor of the jth hyperbolic tangent function term, sin is the sine function, m is the number of sine function terms, η k is the fourth adjustment factor of the kth sine function term, φ k is the fifth adjustment factor of the kth sine function term, ψ k is the sixth adjustment factor of the kth sine function term, ξ l is the seventh adjustment factor of the lth exponential function term, p is the number of exponential function terms, θ l is the eighth adjustment factor of the lth exponential function term, is the first data element value.

[0085] In an optional embodiment, the data element prediction module 302 includes:

[0086] The spatiotemporal analysis unit is configured to perform spatiotemporal analysis on the second data element value according to a preset spatiotemporal analysis function to obtain third data element values ​​at multiple spatial coordinates; wherein the expression of the preset spatiotemporal analysis function is:

[0087]

[0088] Where S(t,x,y) is the value of the third data element at the spatial coordinate (x,y) at time t, p′ is the maximum power of the time t, q′ is the maximum power of the data element value x′, r′ is the maximum power of the data element value y′, and α i′j′k′ is the weight when the power is i′, j′ and k′, t i′ is the i′th power of time t, x ′j′ is the j′th power of the data element value x′ with the horizontal coordinate x in the second data element value after dimensionality reduction, y ′k′ is the k′th power of the data element value y′ with the ordinate y in the second data element value after dimensionality reduction, sin is the sine function, cos is the cosine function, s′ is the number of exponential functions and cosine functions, β l′ is the ninth adjustment factor of the l′th exponential function term, λ l′ is the time-wise adjustment factor of the l′th exponential function term, ω l′ is the eleventh adjustment factor of the l′th cosine function term, θ l′ is the twelfth adjustment factor of the l′th cosine function term, u′ is the number of sine function terms, γ m′ is the thirteenth adjustment factor of the m′th sine function term, μ m′ is the fourteenth adjustment factor of the m′th sine function term, v m′ is the fifteenth adjustment factor of the m′th sine function term, ρ m′ is the sixteenth adjustment factor of the m′th sine function term.

[0089] In an optional embodiment, the data element prediction module 302 includes:

[0090] The prediction unit is configured to input the third data element value into a data element prediction model to obtain a data element prediction value; the input of the data element prediction model is the third data element value, and the output of the data element prediction model is the data element prediction value. The expression of the data element prediction model is:

[0091]

[0092] in, is the predicted value of the data element at time t, u″ is the number of spatiotemporal analysis function terms, λ m″ is the weight of the m″th spatiotemporal analysis function term, S m"" For the mth "" The third data element value corresponding to the spatiotemporal analysis function term, sin is the sine function, cos is the cosine function, w "" is the number of cosine function terms, μ v″ is the seventeenth adjustment factor of the v″th cosine function term, v v″is the eighteenth adjustment factor of the v″th cosine function term, ζ v″ is the nineteenth adjustment factor of the v″th cosine function term, z″ is the number of sine function terms, κ n″ is the twentieth adjustment factor of the n″th sine function term, η n″ is the twenty-first adjustment factor of the n″th sine function term, θ n″ is the twenty-second adjustment factor of the n″th sine function term.

[0093] In an optional embodiment, the encryption processing module 304 includes:

[0094] The hash processing unit is used to encrypt the first hash chain value using asymmetric encryption to obtain a first signature value; and to encrypt the second hash chain value using asymmetric encryption to obtain a second signature value.

[0095] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0096] The river basin data processing device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.

[0097] The embodiment of the present invention also provides a computer device having the above Figure 3 The apparatus for processing river basin data is shown.

[0098] See also Figure 4 , Figure 4 is a structural diagram of a computer device provided by an optional embodiment of the present invention, such as Figure 4 As shown, the computer device includes: one or more processors 10, memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components utilize different buses to communicate with each other and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in the memory or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Equally, multiple computer devices can be connected, and each device provides part of the necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 4 A processor 10 is taken as an example.

[0099] The processor 10 may be a central processing unit, a network processor, or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit, a programmable logic device, or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic, or any combination thereof.

[0100] The memory 20 stores instructions that can be executed by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.

[0101] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and application programs required for at least one function; the data storage area may store data created based on the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely located relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0102] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid-state drive; the memory 20 may also include a combination of the above types of memory.

[0103] The computer device further includes a communication interface 30 for the computer device to communicate with other devices or a communication network.

[0104] The embodiment of the present invention also provides a computer-readable storage medium. The above-mentioned method according to the embodiment of the present invention can be implemented in hardware, firmware, or implemented as a computer code that can be recorded in a storage medium, or implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and downloaded through a network and will be stored in a local storage medium, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state drive, etc.; further, the storage medium can also include a combination of the above-mentioned types of memory. It can be understood that a computer, a processor, a microprocessor controller or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor or hardware, the method shown in the above embodiment is implemented.

[0105] A portion of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the form in which the computer program instruction exists in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc. Accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium that can be accessed by the computer.

[0106] Although the embodiments of the present invention have been described with reference to the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention. Such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A method for processing river basin data, characterized in that: The method comprises: Obtaining a historical original data matrix corresponding to the river basin data, extracting a first data element value from the historical original data matrix, and performing dimensionality reduction processing on the first data element value to obtain a second data element value; performing a spatiotemporal analysis on the second data element value to obtain third data element values ​​at a plurality of spatial coordinates, and predicting a data element value for a preset time period based on the third data element value to obtain a data element prediction value; Performing hash processing on the third data element value to obtain a first hash chain value; performing hash processing on the data element prediction value to obtain a second hash chain value; Encrypting the first Hash chain value to obtain a first signature value; encrypting the second Hash chain value to obtain a second signature value; Upload the first signature value and the second signature value to the blockchain.

2. The method according to claim 1, characterized in that The extracting the first data element value from the historical original data matrix includes: The historical original data matrix is ​​extracted using a preprocessing function to obtain the first data element value; wherein the expression of the preprocessing function is: in, is the first data element value after processing in the i-th row and j-th column of the historical original data matrix, X ij is the data element value of the i-th row and j-th column in the historical original data matrix, X j is the data element value of the jth column in the historical original data matrix, max is the maximum value, min is the minimum value, cos is the cosine function, and log is the logarithmic function.

3. The method according to claim 1 or 2, characterized in that The performing dimensionality reduction processing on the first data element value to obtain the second data element value includes: Performing dimensionality reduction processing on the first data element value using a preset dimensionality reduction model to obtain the second data element value; wherein the expression of the preset dimensionality reduction model is: Among them, Y i is the value of the second data element after the i-th dimension reduction, tanh is the hyperbolic tangent function, n is the number of hyperbolic tangent function terms, γ j is the first adjustment factor of the j-th hyperbolic tangent function term, β j is the second adjustment factor of the j-th hyperbolic tangent function term, δ j is the third adjustment factor of the jth hyperbolic tangent function term, sin is the sine function, m is the number of sine function terms, η k is the fourth adjustment factor of the kth sine function term, φ k is the fifth adjustment factor of the kth sine function term, ψ k is the sixth adjustment factor of the kth sine function term, ξ l is the seventh adjustment factor of the lth exponential function term, p is the number of exponential function terms, θ l is the eighth adjustment factor of the lth exponential function term, is the value of the first data element.

4. The method according to claim 1 or 2, characterized in that The performing spatiotemporal analysis on the second data element value to obtain third data element values ​​at multiple spatial coordinates includes: According to the preset spatiotemporal analysis function, the second data element value is subjected to spatiotemporal analysis to obtain the third data element value under multiple spatial coordinates; wherein the expression of the preset spatiotemporal analysis function is Where S(t, x, y) is the value of the third data element at the spatial coordinate (x, y) at time t, p′ is the maximum power of the time t, q′ is the maximum power of the data element value x′, r′ is the maximum power of the data element value y′, and α i′j′k′ is the weight when the power is i′, j′ and k′, t i′ is the i′th power of time t, x′ j′ is the j′th power of the data element value x′ with the horizontal coordinate x in the second data element value after dimensionality reduction, y′ k′ is the k′th power of the data element value y′ with the ordinate y in the second data element value after dimensionality reduction, sin is the sine function, cos is the cosine function, s′ is the number of exponential functions and cosine functions, β l′ is the ninth adjustment factor of the l′th exponential function term, λ l′ is the time-wise adjustment factor of the l′th exponential function term, ω l′ is the eleventh adjustment factor of the l′th cosine function term, θ l′ is the twelfth adjustment factor of the l′th cosine function term, u′ is the number of sine function terms, γ m′ is the thirteenth adjustment factor of the m′th sine function term, μ m′ is the fourteenth adjustment factor of the m′th sine function term, v m′ is the fifteenth adjustment factor of the m′th sine function term, ρ m ' is the sixteenth adjustment factor of the m'th sine function term.

5. The method according to claim 1 or 2, characterized in that The step of predicting the data element value for a preset time period based on the third data element value to obtain a data element prediction value includes: The third data element value is input into the data element prediction model to obtain the data element prediction value; the input of the data element prediction model is the third data element value, and the output of the data element prediction model is the data element prediction value. The expression of the data element prediction model is: in, is the predicted value of the data element at time t, u″ is the number of the spatiotemporal analysis function terms, and λ m″ is the weight of the m″th spatiotemporal analysis function term, S m″ is the third data element value corresponding to the m″th spatiotemporal analysis function term, sin is the sine function, cos is the cosine function, w″ is the number of cosine function terms, μ v″ is the seventeenth adjustment factor of the v″th cosine function term, v v″ is the eighteenth adjustment factor of the v″th cosine function term, ζ v″ is the nineteenth adjustment factor of the v″th cosine function term, z″ is the number of sine function terms, κ n″ is the twentieth adjustment factor of the n″th sine function term, η n″ is the twenty-first adjustment factor of the n″th sine function term, θ n″ is the twenty-second adjustment factor of the n″th sine function term.

6. The method according to claim 1 or 2, characterized in that encrypting the first hash chain value to obtain a first signature value; Encrypting the second hash chain value to obtain a second signature value includes: The first Hash chain value is encrypted using asymmetric encryption to obtain the first signature value; the second Hash chain value is encrypted using asymmetric encryption to obtain the second signature value.

7. A river basin data processing device, characterized in that: The device comprises: a data preprocessing module, configured to obtain a historical raw data matrix of a target area, extract a first data element value from the historical raw data matrix, and perform dimensionality reduction processing on the first data element value to obtain a second data element value; a data element prediction module, configured to perform a spatiotemporal analysis on the second data element value to obtain a third data element value at a plurality of spatial coordinates, and predict a data element value for a preset time period based on the third data element value to obtain a data element prediction value; a hash processing module, configured to perform hash processing on the third data element value to obtain a first hash chain value; and perform hash processing on the data element prediction value to obtain a second hash chain value; an encryption processing module, configured to encrypt the first Hash chain value to obtain a first signature value; and encrypt the second Hash chain value to obtain a second signature value; The blockchain uploading module is used to upload the first signature value and the second signature value to the blockchain.

8. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the river basin data processing method according to any one of claims 1 to 6 by executing the computer instructions.

9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the river basin data processing method according to any one of claims 1 to 6.

10. A computer program product, characterized in that The method comprises computer instructions for causing a computer to execute the river basin data processing method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Intrusion detection method based on deep residual hash network

    CN111614665A

  • Data integrity verification method and system based on block chain

    CN116069856A