A power data acquisition method and device based on a logarithmic amplifier and a medium
By generating hybrid observation vectors and using real-time temperature compensation, the problem of inaccurate temperature compensation and difficulty in simultaneously acquiring transient signals in power data acquisition is solved. This achieves high-precision measurement and accurate detection of transient signals over a wide temperature range, while reducing transmission bandwidth and storage requirements.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHENGDU ANPRI ELECTRONICS CO LTD
- Filing Date
- 2026-01-27
- Publication Date
- 2026-05-05
AI Technical Summary
Existing power data acquisition technologies suffer from inaccurate temperature compensation and difficulty in simultaneously acquiring transient signals. In particular, measurement errors are large in wide temperature ranges and complex electromagnetic environments. Furthermore, traditional fixed-rate sampling strategies cannot simultaneously achieve high-precision measurement of power frequency signals and complete capture of transient signals.
By generating a hybrid observation vector, the temperature characteristic correction parameters are calculated in real time using the temperature-parameter mapping relationship. Logarithmic compression and high-speed analog-to-digital conversion are performed, and the sampling rate is dynamically adjusted by combining priority buffering and differential operation to achieve real-time temperature compensation and transient signal detection of the logarithmic amplifier.
It achieves consistent measurement accuracy across a wide temperature range, reduces transmission bandwidth and storage requirements, improves the accuracy of transient event detection, and reduces the false alarm rate.
Smart Images

Figure CN121577956B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power monitoring signal processing technology, and in particular to a power data acquisition method, device and medium based on a logarithmic amplifier. Background Technology
[0002] With the rapid development of smart grids and the Internet of Things in the power sector, power condition monitoring places higher demands on the dynamic range, accuracy, and adaptability of data acquisition technologies. In the field of power data acquisition, signal conditioning techniques based on logarithmic amplifiers have received widespread attention due to their ability to effectively compress the dynamic range of signals. In recent years, solutions based on compressed sensing, adaptive sampling, and smart sensor technologies have improved the processing capability of large dynamic signals to some extent through algorithm optimization and hardware integration. However, these technologies still have significant limitations in areas such as temperature drift compensation and real-time performance assurance. Existing technologies often employ temperature sensors combined with lookup tables for offline calibration or achieve dynamic range expansion through multi-channel parallel processing. These methods struggle to balance system complexity and real-time requirements. Especially when operating over a wide temperature range in complex electromagnetic environments, the nonlinear characteristics of logarithmic amplifiers can introduce significant measurement errors.
[0003] Current power data acquisition technology suffers from two main shortcomings: First, existing temperature compensation mechanisms mostly employ static parameter calibration, which fails to achieve dynamic tracking and adaptive correction of the logarithmic amplifier's operating point. This results in difficulty maintaining consistent compression characteristics across a wide temperature range of -40℃ to 85℃, affecting long-term measurement accuracy. Even intelligent sensors with some self-diagnostic capabilities struggle to achieve real-time closed-loop optimization of the logarithmic amplifier's core parameters. Second, traditional fixed-rate sampling strategies cannot simultaneously achieve high-precision measurement of power frequency signals and complete capture of transient signals. The method of using fixed threshold trigger mode switching is prone to misjudgment when dealing with complex operating conditions and lacks intelligent learning capabilities for signal characteristics. Existing intelligent sensors primarily focus on data uploading and protocol conversion, with limited functionality in dynamic optimization and autonomous decision-making of acquisition strategies. Summary of the Invention
[0004] In view of the aforementioned existing problems, the present invention is proposed.
[0005] Therefore, this invention provides a power data acquisition method based on a logarithmic amplifier to solve the problems of inaccurate temperature compensation and difficulty in simultaneously acquiring transient signals in the prior art.
[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:
[0007] In a first aspect, the present invention provides a power data acquisition method based on a logarithmic amplifier, comprising: acquiring a raw analog current signal from a power line and an analog temperature signal from the environment where the logarithmic amplifier is located, generating a hybrid observation vector; based on the hybrid observation vector, calculating an estimated value of a temperature characteristic correction parameter in real time through a pre-stored temperature-parameter mapping relationship, and using the estimated value of the temperature characteristic correction parameter to perform logarithmic compression on the raw current digital signal sequence to obtain a temperature-compensated compressed voltage signal; performing high-speed analog-to-digital conversion on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence, and storing the discrete digital signal sequence in a priority buffer area; extracting a real-time signal gradient from the discrete digital signal sequence in the priority buffer area, calculating the average gradient of the real-time signal gradient within a preset time window as a steady-state reference gradient, and performing a difference operation between the real-time signal gradient and the steady-state reference gradient to generate a difference value sequence; comparing the difference values in the difference value sequence with a first discrimination threshold and a second discrimination threshold to obtain a transient data packet.
[0008] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the steps for acquiring the original analog current signal from the power line and the analog temperature signal from the environment where the logarithmic amplifier is located, and generating a hybrid observation vector, are as follows:
[0009] Simultaneously acquire the raw analog current signal on the power line and the analog temperature signal around the logarithmic amplifier at a sampling rate higher than the Nyquist frequency;
[0010] The original analog current signal and analog temperature signal are converted from analog to digital respectively to obtain the original digital current signal sequence and the digital temperature signal sequence.
[0011] The original digital current signal sequence and the digital temperature signal sequence are combined to construct a multidimensional signal vector;
[0012] A matrix multiplication operation is performed between the multidimensional signal vector and the pre-generated block diagonal compressed sensing matrix to generate a hybrid observation vector.
[0013] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the step of calculating the estimated value of the temperature characteristic correction parameter in real time based on a hybrid observation vector and a pre-stored temperature-parameter mapping relationship includes the following specific steps.
[0014] Based on the pre-stored temperature-parameter mapping relationship, a Gaussian random field is constructed to describe the distribution characteristics of the temperature characteristic correction parameter.
[0015] Using the probability structure defined by the Gaussian random field as the prior distribution, and combining it with the mixed observation vector, a probabilistic inference framework for temperature characteristic correction parameters is constructed.
[0016] Based on the probabilistic inference framework, by maximizing the lower bound of evidence, a variational optimization equation for estimating the temperature characteristic correction parameters is derived.
[0017] The coordinate ascent algorithm is used to iteratively solve the variational optimization equation in real time and calculate the estimated values of the temperature characteristic correction parameters.
[0018] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the specific steps for performing logarithmic compression on the original digital current signal sequence using the estimated value of the temperature characteristic correction parameter to obtain a temperature-compensated compressed voltage signal are as follows:
[0019] Based on the estimated values of the temperature characteristic correction parameters, a nonlinear compression function relationship with temperature-dependent characteristics is constructed.
[0020] Based on the nonlinear compression function relationship, the original current digital signal sequence is transformed in real time using a numerical integration algorithm to generate a preliminary compressed voltage signal sequence.
[0021] Dynamic range calibration and signal smoothing are performed on the initial compressed voltage signal sequence to obtain a temperature-compensated compressed voltage signal.
[0022] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the steps of performing high-speed analog-to-digital conversion on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence and storing the discrete digital signal sequence in a priority buffer area are as follows:
[0023] The temperature-compensated compressed voltage signal is analyzed in real time through a transient feature detection mechanism to dynamically obtain the optimal sampling rate parameter;
[0024] Based on the optimal sampling rate parameter, the analog-to-digital converter is controlled to perform incremental modulation on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence;
[0025] A multi-priority cache management strategy is used to store discrete digital signal sequences into a priority cache area.
[0026] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the steps of extracting the real-time signal gradient from the discrete digital signal sequence in the priority buffer region and calculating the average gradient of the real-time signal gradient within a preset time window as the steady-state reference gradient are as follows:
[0027] Read the discrete digital signal sequence from the priority buffer area and obtain the real-time signal gradient of the discrete digital signal sequence;
[0028] Variational mode decomposition of real-time signal gradients yields multiple essential mode functions;
[0029] Sparse encoding is performed on multiple essential mode functions to select gradient components that meet the sparse energy threshold.
[0030] The gradient components are used to calculate the weighted average gradient value within a preset time window as the steady-state reference gradient.
[0031] As a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the specific steps for performing a differential operation between the real-time signal gradient and the steady-state reference gradient to generate a differential value sequence are as follows:
[0032] Calculate the reference difference between the real-time signal gradient and the steady-state reference gradient;
[0033] The baseline difference value is processed using the stochastic differential probability method to obtain a probability-transformed difference sequence;
[0034] Fourier spectrum filtering is applied to the probability transform difference sequence to generate a difference value sequence.
[0035] In a preferred embodiment of the power data acquisition method based on a logarithmic amplifier described in this invention, the specific steps for comparing the difference values in the difference value sequence with a first discrimination threshold and a second discrimination threshold to obtain transient data packets are as follows.
[0036] The differential value sequence is monitored. When the differential value in the differential value sequence is continuously lower than the first discrimination threshold, it is determined that the current state is in power frequency steady state mode, and the optimal low sampling rate is obtained based on the steady state reference gradient to collect power data.
[0037] When the difference value in the difference value sequence exceeds the second discrimination threshold, it is determined to be a transient event mode, and a high sampling rate is maintained and the buffer is locked to generate a transient data packet.
[0038] In a second aspect, the present invention provides a computer device including a memory and a processor, wherein the memory stores a computer program, wherein the computer program, when executed by the processor, implements any step of the power data acquisition method based on a logarithmic amplifier as described in the first aspect of the present invention.
[0039] Thirdly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements any step of the power data acquisition method based on a logarithmic amplifier as described in the first aspect of the present invention.
[0040] The beneficial effects of this invention are as follows: by generating a hybrid observation vector through a block diagonal compressed sensing matrix, the intelligent sensor realizes the joint representation of multi-source signals in the compressed domain, and utilizes the correlation between signals to achieve effective compression of data volume, reducing transmission bandwidth and storage requirements, while maintaining the accuracy of signal reconstruction; by processing the differential value sequence through the random differential probability method, the problem of high false alarm rate of the fixed threshold method in noisy environments is solved, which greatly reduces the false alarm rate of transient event detection. Attached Figure Description
[0041] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0042] Figure 1 This is a flowchart of a power data acquisition method based on a logarithmic amplifier.
[0043] Figure 2 The flowchart for generating the hybrid observation vector.
[0044] Figure 3 A flowchart for obtaining a temperature-compensated compressed voltage signal.
[0045] Figure 4 This is a flowchart for generating the difference value sequence. Detailed Implementation
[0046] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
[0047] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.
[0048] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.
[0049] Reference Figures 1-4 This is one embodiment of the present invention, which provides a power data acquisition method based on a logarithmic amplifier, comprising the following steps:
[0050] S1. Collect the original analog current signal on the power line and the analog temperature signal of the environment where the logarithmic amplifier is located, and generate a hybrid observation vector.
[0051] Simultaneously acquire the raw analog current signal on the power line and the analog temperature signal around the logarithmic amplifier at a sampling rate higher than the Nyquist frequency.
[0052] The specific process includes: acquiring the original analog current signal on the power line by sensing the current in the power line through a current transformer or Hall current sensor, and converting it into a continuously changing voltage signal output; acquiring the analog temperature signal around the logarithmic amplifier by placing a temperature sensor near the logarithmic amplifier to sense the ambient temperature and output a corresponding continuous voltage signal; the output terminals of the two sensors are respectively connected to the two input channels of the analog-to-digital converter, and under the same sampling clock, the voltage amplitude of the original analog current signal on the power line and the analog temperature signal around the logarithmic amplifier are sampled simultaneously at each sampling moment, thereby obtaining the time-synchronized analog signal sample values of the power line and the logarithmic amplifier.
[0053] The original analog current signal and analog temperature signal are converted from analog to digital respectively to obtain the original digital current signal sequence and the digital temperature signal sequence.
[0054] The specific process includes inputting the original analog current signal from the power line into an analog-to-digital converter (ADC) channel, and simultaneously inputting the analog temperature signal from the periphery of the logarithmic amplifier into another ADC channel. Each of the two channels independently quantizes and encodes its input signal according to the same sampling clock. The ADC samples and quantizes the original analog current signal at each sampling moment, mapping its instantaneous voltage amplitude to the corresponding digital codeword, forming a sequence of original current digital signals arranged in chronological order. Similarly, the ADC samples and quantizes the analog temperature signal at sampling moments synchronized with the original analog current signal, mapping its instantaneous voltage amplitude to the corresponding digital codeword, forming a sequence of temperature digital signals arranged in chronological order.
[0055] The original digital current signal sequence and the digital temperature signal sequence are combined to construct a multidimensional signal vector.
[0056] The specific process includes taking a value from the original current digital signal sequence and a value from the temperature digital signal sequence at each sampling time, and arranging them in a fixed order to form a column vector or row vector containing two elements. As the sampling time progresses, all such vectors at all times together form a multidimensional signal vector composed of the original current digital signal sequence and the temperature digital signal sequence.
[0057] A matrix multiplication operation is performed between the multidimensional signal vector and the pre-generated block diagonal compressed sensing matrix to generate a hybrid observation vector.
[0058] The specific process includes taking the multidimensional signal vector composed of the original current digital signal sequence and the temperature digital signal sequence as a column vector, multiplying it with a pre-constructed block diagonal compressed sensing matrix. The block diagonal compressed sensing matrix is composed of multiple sub-matrices arranged along the main diagonal and the elements at the off-diagonal positions are zero. Through standard matrix multiplication operations, the multidimensional signal vector is projected onto a low-dimensional space to obtain a hybrid observation vector with a dimension lower than that of the multidimensional signal vector.
[0059] It should be noted that the block diagonal compressed sensing matrix is a sparse matrix composed of multiple sub-matrices arranged along the main diagonal, with all elements at off-diagonal positions being zero. Each sub-matrix of the block diagonal compressed sensing matrix is a random matrix that satisfies the finite isometric property, and its elements typically follow a Gaussian distribution, a Bernoulli distribution, or a combination of partial Fourier coefficients. When pre-generating the block diagonal compressed sensing matrix, the number of rows and columns of the corresponding sub-matrix are determined according to the data dimensions of the original current digital signal sequence and the temperature digital signal sequence, so that each sub-matrix acts independently on the corresponding signal component in the multidimensional signal vector. A random matrix construction method is used to determine the number of rows of the overall matrix according to a preset compression ratio, while keeping each sub-matrix independent and structurally fixed, thereby forming a complete block diagonal compressed sensing matrix.
[0060] The compression ratio is determined based on the sparsity of the original digital current signal sequence and the digital temperature signal sequence, as well as the data volume requirements. Offline testing is used to ensure that the ratio of the number of rows to the number of columns in the block diagonal compressed sensing matrix equals the compression ratio.
[0061] Random matrix construction methods refer to techniques for generating matrices whose elements have a specific probability distribution and satisfy the requirements of compressed sensing theory. Typically, the matrix elements are made to independently and identically distributed follow a Gaussian distribution, a Bernoulli distribution, or are constructed by randomly selecting rows from a portion of the Fourier matrix. The generated random matrix satisfies the finite isometry property with a high probability, thereby ensuring that sparse signals can still be accurately reconstructed after projection. Random matrix construction methods are widely used to construct measurement matrices or sensing matrices.
[0062] S2. Based on the hybrid observation vector, the estimated value of the temperature characteristic correction parameter is calculated in real time through the pre-stored temperature-parameter mapping relationship. The estimated value of the temperature characteristic correction parameter is then used to perform logarithmic compression on the original current digital signal sequence to obtain the temperature-compensated compressed voltage signal.
[0063] Based on the pre-stored temperature-parameter mapping relationship, a Gaussian random field is constructed to describe the distribution characteristics of the temperature characteristic correction parameter.
[0064] The specific process includes using multiple temperature values and corresponding temperature characteristic correction parameters contained in the pre-stored temperature-parameter mapping relationship as training samples, and using a Gaussian random field to model the input-output dependency structure reflected by the training samples. The temperature value is used as the input and the temperature characteristic correction parameter is used as the output. The mean function is usually set to zero or a constant, and the covariance function is selected in the form of squared exponent. The hyperparameters of the covariance function are determined through the training samples, thereby expressing the variation law of the temperature characteristic correction parameter in the temperature domain as a Gaussian random field with a specific mean function and covariance function.
[0065] It should be noted that the temperature-parameter mapping relationship is the correspondence between the temperature characteristic correction parameters at different temperatures. It is obtained by calibrating the logarithmic amplifier at multiple known temperature points and stored in the non-volatile storage medium of the device in the form of data.
[0066] Using the probability structure defined by Gaussian random fields as the prior distribution, and combining it with mixed observation vectors, a probabilistic inference framework for temperature characteristic correction parameters is constructed.
[0067] The specific process includes: taking the statistical property that the temperature characteristic correction parameter at any temperature follows a joint Gaussian distribution given by the Gaussian random field as prior knowledge; extracting the prior mean and covariance of the temperature characteristic correction parameter at the corresponding temperature point from the Gaussian random field, given the temperature value corresponding to the simulated temperature signal around the current logarithmic amplifier; simultaneously, establishing a likelihood function with the temperature characteristic correction parameter as the variable based on the linear or nonlinear observation relationship between the mixed observation vector and the original current digital signal sequence; multiplying the prior distribution and the likelihood function according to Bayes' rule and normalizing them to obtain the posterior probability distribution of the temperature characteristic correction parameter, thus forming a complete probabilistic inference framework for the temperature characteristic correction parameter that can be used for subsequent estimation.
[0068] It should be noted that Bayes' rule is a fundamental theorem in probability theory, used to update the probability of another related event given that the occurrence of a certain event is known. It is directly derived from the definition of conditional probability.
[0069] Based on a probabilistic inference framework, a variational optimization equation for estimating temperature characteristic correction parameters is derived by maximizing the lower bound of evidence.
[0070] The specific process includes, when the posterior probability distribution of the temperature characteristic correction parameter is difficult to calculate directly, combining an adjustable approximate distribution, constructing an evidence lower bound between the approximate distribution and the true posterior distribution, using variational inference methods to transform the original inference problem into an optimization problem of the evidence lower bound, and obtaining a set of variational optimization equations for the temperature characteristic correction parameter by differentiating the evidence lower bound with respect to the approximate distribution parameter and setting the derivative to zero.
[0071] It should be noted that variational inference is a deterministic inference method used to approximate complex posterior probability distributions. The core idea is to transform the probability inference problem into an optimization problem by combining a simple and easy-to-process family of approximate distributions and finding the member in the family that is closest to the true posterior distribution. "Closest" is usually defined by minimizing the KL divergence between the two, which is equivalent to maximizing the lower bound of evidence. Variational inference is suitable for large-scale data and real-time scenarios.
[0072] The coordinate ascent algorithm is used to iteratively solve the variational optimization equation in real time, and the estimated values of the temperature characteristic correction parameters are calculated. The expression is as follows:
[0073] ;
[0074] in, Indicates in In the iteration, the temperature characteristic correction parameter is... The estimated value of each component, The index representing the iteration number. Indicates the component index of the temperature characteristic correction parameter. Indicates in In the iteration, the temperature characteristic correction parameter is... The estimated value of each component, Indicates the baseline learning rate. Indicates the first In the next iteration, the currently estimated temperature characteristic parameters are corrected. After substituting into the objective function The obtained function value, The first parameter in the temperature characteristic correction parameter vector represents the... One portion, This represents the damping coefficient.
[0075] It should be noted that the baseline learning rate is a positive scalar used to control the step size of each update of the temperature characteristic correction parameter during the iterative solution of the variational optimization equation using the coordinate ascent algorithm; the baseline learning rate is determined after balancing convergence speed and stability under typical operating conditions.
[0076] The damping coefficient is a positive scalar used to suppress oscillations caused by excessive gradient magnitude during the update of temperature characteristic correction parameters. It is selected through offline parameter tuning while ensuring convergence stability.
[0077] The specific process includes: in each iteration, sequentially traversing each component of the temperature characteristic correction parameter; for the currently selected component, while keeping the values of all other components unchanged, calculating the local optimal update direction and step size of the component under the current evidence lower bound function, and replacing the current value of the component with this update result; after completing one round of updating all components, repeating the above process again starting from the first component, continuously looping until the overall change of the temperature characteristic correction parameter in two consecutive iterations reaches the maximum number of iterations, and outputting the temperature characteristic correction parameter at this time as an estimated value.
[0078] The coordinate ascent algorithm is an iterative optimization method that updates only one variable at a time while keeping the others fixed, and alternates all variables in turn to gradually improve the objective function value until convergence.
[0079] Based on the estimated values of the temperature characteristic correction parameters, a nonlinear compression function relationship with temperature-dependent characteristics is constructed.
[0080] The specific process includes using the estimated value of the temperature characteristic correction parameter as an adjustable parameter in the nonlinear compression operation of the logarithmic amplifier, so that the compression slope or intercept used by the logarithmic amplifier to compress the original current digital signal sequence changes dynamically with the current estimated value of the temperature characteristic correction parameter, thereby forming a nonlinear compression function relationship with the original current digital signal sequence as input, the compressed voltage signal as output, and the nonlinear mapping form determined by the estimated value of the temperature characteristic correction parameter.
[0081] Based on the nonlinear compression function relationship, the original current digital signal sequence is transformed in real time using a numerical integration algorithm to generate a preliminary compressed voltage signal sequence.
[0082] The specific process includes substituting the current value in the original current digital signal sequence into the nonlinear compression function relationship at each sampling time, and using numerical integration algorithms such as the trapezoidal method or Euler method to solve the output of the nonlinear compression function relationship under the current input, thereby obtaining the corresponding compressed voltage value point by point, and arranging the compressed voltage values obtained at all times in sequence to form a preliminary compressed voltage signal sequence.
[0083] Dynamic range calibration and signal smoothing are performed on the initial compressed voltage signal sequence to obtain a temperature-compensated compressed voltage signal.
[0084] The specific process includes adjusting the amplitude range of the initial compressed voltage signal sequence to within the effective input range of the analog-to-digital converter to complete the dynamic range calibration, and using signal smoothing processing methods such as moving average filtering or low-pass filtering to suppress high-frequency fluctuations in the initial compressed voltage signal sequence caused by quantization or environmental interference. The final output signal is the temperature-compensated compressed voltage signal.
[0085] S3. Perform high-speed analog-to-digital conversion on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence, and store the discrete digital signal sequence in the priority buffer area.
[0086] The temperature-compensated compressed voltage signal is analyzed in real time using a transient feature detection mechanism to dynamically obtain the optimal sampling rate parameter.
[0087] The specific process includes continuously monitoring the amplitude change rate or gradient characteristics of the temperature-compensated compressed voltage signal using a transient feature detection mechanism. When a rapid change in the compressed voltage signal is detected, it is determined to be a transient event (e.g., a sudden increase in short-circuit current, voltage drop caused by load switching, lightning overvoltage, or arc fault, etc.). Based on this, the sampling rate is increased to capture details. When the signal is in a slow change or stable state, the sampling rate is reduced to reduce the amount of data. Thus, the sampling rate parameter is continuously adjusted and output during operation to achieve the most suitable sampling rate parameter.
[0088] It should be noted that the transient feature detection mechanism consists of a real-time signal gradient extraction unit and a gradient change discrimination unit for the temperature-compensated compressed voltage signal, which is used to detect whether the signal has undergone transient changes.
[0089] Based on the optimal sampling rate parameter, the analog-to-digital converter is controlled to perform incremental modulation on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence.
[0090] The specific process includes using the optimal sampling rate parameter to configure the sampling clock frequency of the analog-to-digital converter (ADC), enabling the ADC to read the instantaneous amplitude of the temperature-compensated compressed voltage signal at each sampling moment determined by the sampling rate, and to obtain the current error signal based on the reconstructed signal value from the previous moment. During the incremental modulation process, different quantization step sizes are assigned probability weights based on the statistical characteristics or trends of the error signal. The current incremental step size is selected according to the probability weights, and the corresponding sign bit or multi-bit incremental code is output, thus forming a discrete digital signal sequence corresponding to the temperature-compensated compressed voltage signal point by point.
[0091] A multi-priority cache management strategy is used to store discrete digital signal sequences into a priority cache area.
[0092] The specific process includes dividing the discrete digital signal sequence into different priority levels according to the signal characteristics or transient importance of each data point in the discrete digital signal sequence at the sampling time, and writing them into the corresponding priority storage sub-area in the priority cache area according to their priority. High-priority data is allocated to a cache location with lower access latency or stronger protection, while low-priority data is stored in a normal cache location, thereby realizing differentiated storage management of the discrete digital signal sequence.
[0093] It should be noted that the multi-priority cache management strategy is a management method that divides data into multiple priorities based on their importance and allocates storage resources in the cache according to priority. By analyzing the signal characteristics corresponding to each data point in the discrete digital signal sequence, such as whether it is in a transient event period or the magnitude of the gradient, the data is marked as high, medium, or low priority. High-priority data is written to a cache area that is accessed faster or is more protected, while low-priority data is stored in the ordinary area.
[0094] S4. Extract the real-time signal gradient from the discrete digital signal sequence in the priority buffer area, calculate the average gradient of the real-time signal gradient within a preset time window as the steady-state reference gradient, and perform a difference operation between the real-time signal gradient and the steady-state reference gradient to generate a difference value sequence.
[0095] Read the discrete digital signal sequence from the priority buffer area and obtain the real-time signal gradient of the discrete digital signal sequence.
[0096] The specific process includes retrieving the current sample and the previous sample of the discrete digital signal sequence from the priority buffer area in chronological order, processing these two continuous samples using the first-order difference method, and obtaining the real-time signal gradient that characterizes the instantaneous rate of change of the signal.
[0097] Variational mode decomposition is performed on the gradient of the real-time signal to obtain multiple essential mode functions.
[0098] The specific process includes taking the real-time signal gradient as the input signal and using the variational mode decomposition method to decompose the real-time signal gradient into several components with different center frequencies and bandwidths. Each component is a narrowband signal and satisfies the band-limiting characteristic. These components are the essential mode functions.
[0099] It should be noted that a narrowband signal refers to a signal whose spectral energy is concentrated in a relatively narrow frequency range, which is much smaller than the center frequency of the signal. In the time domain, a narrowband signal exhibits an oscillation of approximately a single frequency, whose amplitude and phase can change slowly, but the carrier frequency remains basically constant. In variational mode decomposition, each essential mode function is constrained to a narrowband signal to ensure that each component has good separability and physical interpretability in the frequency domain.
[0100] Band-limited characteristics refer to the fact that the spectrum of a signal has non-zero values only within a finite frequency range in the frequency domain, while the spectral values outside this range are strictly zero. Signals with band-limited characteristics are restricted to a certain maximum frequency range in the frequency domain, and the highest frequency component does not exceed a certain cutoff frequency. Band-limited characteristics are a prerequisite for the Nyquist sampling theorem to hold, and also an important theoretical basis for constraining each essential mode function to be a narrowband signal in variational mode decomposition.
[0101] Sparse encoding is performed on multiple essential mode functions to select gradient components that meet the sparse energy threshold.
[0102] The specific process includes representing each essential mode function as a coefficient vector under a preset basis or dictionary, obtaining the energy concentration degree or non-zero coefficient ratio of the coefficient vector, retaining essential mode functions whose energy ratio is higher than the sparse energy threshold as effective gradient components, and discarding the rest.
[0103] It should be noted that the sparse energy threshold is preset based on offline statistical analysis of the energy distribution of the essential mode functions under typical operating conditions. By collecting real-time signal gradients under multiple steady-state and transient operating conditions, performing variational mode decomposition, and calculating the energy proportion of each essential mode function, the boundary value that can effectively distinguish between noise components and effective gradient components is selected as the sparse energy threshold; the exemplary value range is between 5% and 20%.
[0104] The gradient components are used to calculate the weighted average gradient value within a preset time window as the steady-state baseline gradient, expressed as follows:
[0105] ;
[0106] in, Represents at discrete time points The weighted average gradient value at that point. Indicates the sampling sequence number at discrete time points. Indicates the length of the preset time window. Indicates the relative time index within the time window. Indicates relative time index The corresponding weight coefficient value, Indicates the index number of the gradient component. This represents the set of gradient components to be selected. Indicates the first The gradient components at discrete time points are: The instantaneous value at time.
[0107] It should be noted that the preset time window is based on the power frequency cycle characteristics of the power signal and the typical duration of transient events. By analyzing the change law of the signal gradient under the power frequency steady state, the time length that can cover multiple complete power frequency cycles and is sufficient to smooth random disturbances is selected as the preset time window.
[0108] Indicates relative time index The corresponding weight coefficient value is the value used to weight the historical gradient components at the relative time index. It is determined and fixed before device deployment through a decay function such as exponential decay or linear decay.
[0109] Indicates the first The gradient components at discrete time points are: The instantaneous value at time is obtained by processing the discrete digital signal sequence read from the priority buffer area through real-time signal gradient extraction, variational mode decomposition, and sparse coding. The output value of each effective gradient component at the corresponding time.
[0110] The specific process includes arranging the values of the selected gradient components at the current time and several previous times in chronological order, assigning different weights to these values within a preset time window, assigning higher weights to values closer to the current time and lower weights to values at earlier times, and summing and normalizing all weighted gradient component values to obtain the steady-state baseline gradient.
[0111] The reference difference between the real-time signal gradient and the steady-state reference gradient is calculated using the following expression:
[0112] ;
[0113] in, Represents at discrete time points The reference difference between the real-time signal gradient and the steady-state reference gradient. This represents the total dimension of the feature vector. This represents the dimension index of the gradient component in the feature vector. Represents at discrete time points The eigenvector of the real-time signal gradient at the eigenvector is the first Each component value Represents at discrete time points The eigenvector of the steady-state reference gradient is the first... Each component value.
[0114] The specific process includes: at each discrete time point, representing the real-time signal gradient and the steady-state reference gradient as eigenvectors composed of multiple gradient components, calculating the inner product of the two eigenvectors, and simultaneously calculating the square root of the sum of squares of each component of each eigenvector. The inner product and the product of the two square roots are normalized to obtain the cosine similarity. Then, based on the cosine similarity, a difference measure between zero and one is obtained through complementation. This difference measure is the reference difference value.
[0115] The baseline difference value is processed using the stochastic differential probability method to obtain the probability transformation difference sequence.
[0116] The specific process includes inputting the baseline difference value at each time moment into the processing flow specified by the stochastic differential probability method. This processing flow, based on the dynamic rules described by the stochastic differential equation, converts the baseline difference value into a probabilistic output that may take values under random perturbation. The probabilistic outputs corresponding to each time moment are arranged in chronological order to form a probability transformation difference sequence.
[0117] Dynamic rules refer to the probabilistic changes of variables described by stochastic differential equations over time. They are usually the sum of a drift term and a diffusion term. The drift term describes the deterministic trend of the baseline difference value under noise-free conditions, while the diffusion term describes the uncertainty disturbances introduced by stochastic processes such as Brownian motion. Dynamic rules specify how the probabilistic output at the current moment depends on the state at the previous moment and the cumulative effect of random disturbances, thereby generating an output sequence with continuous paths and inherent randomness as time progresses.
[0118] Fourier spectrum filtering is applied to the probability transform difference sequence to generate a difference value sequence.
[0119] The specific process includes transforming the probability transform differential sequence from the time domain to the frequency domain, setting the passband and stopband ranges according to the differences in frequency distribution between transient events and steady-state noise in the power signal, retaining the effective frequency bands that reflect transient characteristics and suppressing irrelevant frequency bands, and then transforming the filtered frequency domain signal back to the time domain to obtain the differential value sequence after spectrum filtering.
[0120] S5. Compare the difference values in the difference value sequence with the first discrimination threshold and the second discrimination threshold to obtain the transient data packet.
[0121] The differential value sequence is monitored. When the differential value in the differential value sequence is continuously lower than the first discrimination threshold, it is determined that the current state is in the power frequency steady state mode, and the optimal low sampling rate is obtained based on the steady state reference gradient to collect power data.
[0122] The specific process includes continuously observing the difference values at each time point in the difference value sequence. If the difference values at multiple consecutive time points are all less than the first discrimination threshold, it is considered that the power signal has not experienced transient disturbances and is in the power frequency steady-state mode. At this time, based on the smooth signal change characteristics reflected by the steady-state reference gradient, the lowest sampling frequency that can meet the power frequency signal reconstruction accuracy requirements (such as accurately restoring the amplitude and phase of the current waveform within half or one complete power frequency cycle, ensuring that the harmonic components are not distorted, and meeting the minimum time resolution requirements of the power metering or protection device for the sampled data) is selected as the optimal low sampling rate, and subsequent power data acquisition is performed using this sampling rate.
[0123] It should be noted that the first discrimination threshold is preset based on the statistical characteristics of the differential value sequence under the power frequency steady-state mode. By collecting a large number of differential value samples under typical steady-state conditions, analyzing the distribution of the differential value sequence under the power frequency steady-state mode, and selecting a value slightly higher than the upper limit of steady-state fluctuation as the first discrimination threshold; the exemplary value range is between 0.01 and 0.05.
[0124] When the difference value in the difference value sequence exceeds the second discrimination threshold, it is determined to be a transient event mode, and a high sampling rate is maintained and the buffer is locked to generate a transient data packet.
[0125] The specific process includes the following steps: during the continuous monitoring of the differential value sequence, once the differential value at any time is found to be higher than the second discrimination threshold, it is determined that a short-term sudden change or abnormal disturbance has occurred in the power signal, and the transient event mode is entered. At this time, the high sampling rate used to capture rapidly changing signals is kept unchanged, and the discrete digital signal sequence related to the transient event in the priority buffer area is fixedly stored to prevent it from being overwritten. Then, the fixed discrete digital signal sequence is encapsulated into a transient data packet.
[0126] In summary, this invention achieves the following: by generating a hybrid observation vector using a block diagonal compressed sensing matrix, the intelligent sensor enables joint representation of multi-source signals in the compressed domain, and the correlation between signals is used to effectively compress the data volume, reducing transmission bandwidth and storage requirements while maintaining the accuracy of signal reconstruction; by processing the difference value sequence using a random differential probability method, the problem of high false alarm rate of the fixed threshold method in noisy environments is solved, resulting in a significant reduction in the false alarm rate of transient event detection.
[0127] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A power data acquisition method based on a logarithmic amplifier, characterized in that: include, The raw analog current signal from the power line and the analog temperature signal from the environment where the logarithmic amplifier is located are collected to generate a hybrid observation vector. Based on the hybrid observation vector, the estimated values of the temperature characteristic correction parameters are calculated in real time through the pre-stored temperature-parameter mapping relationship. The estimated values of the temperature characteristic correction parameters are then used to perform logarithmic compression on the original current digital signal sequence to obtain a temperature-compensated compressed voltage signal. The specific steps are as follows: Based on the pre-stored temperature-parameter mapping relationship, a Gaussian random field is constructed to describe the distribution characteristics of the temperature characteristic correction parameter. Using the probability structure defined by the Gaussian random field as the prior distribution, and combining it with the mixed observation vector, a probabilistic inference framework for temperature characteristic correction parameters is constructed. Based on the probabilistic inference framework, by maximizing the lower bound of evidence, a variational optimization equation for estimating the temperature characteristic correction parameters is derived. The coordinate ascent algorithm is used to iteratively solve the variational optimization equation in real time and calculate the estimated values of the temperature characteristic correction parameters. Based on the estimated values of the temperature characteristic correction parameters, a nonlinear compression function relationship with temperature-dependent characteristics is constructed. Based on the nonlinear compression function relationship, the original current digital signal sequence is transformed in real time using a numerical integration algorithm to generate a preliminary compressed voltage signal sequence. Dynamic range calibration and signal smoothing are performed on the initial compression voltage signal sequence to obtain a temperature-compensated compression voltage signal. The temperature-compensated compressed voltage signal is subjected to high-speed analog-to-digital conversion to obtain a discrete digital signal sequence, and the discrete digital signal sequence is stored in a priority buffer area. Extract the real-time signal gradient from the discrete digital signal sequence in the priority buffer area, calculate the average gradient of the real-time signal gradient within a preset time window as the steady-state reference gradient, and perform a difference operation between the real-time signal gradient and the steady-state reference gradient to generate a difference value sequence. The difference values in the difference value sequence are compared with the first discrimination threshold and the second discrimination threshold to obtain the transient data packet.
2. The power data acquisition method based on a logarithmic amplifier as described in claim 1, characterized in that: The process involves acquiring the original analog current signal from the power line and the analog temperature signal from the environment where the logarithmic amplifier is located, and generating a hybrid observation vector. The specific steps are as follows: Simultaneously acquire the raw analog current signal on the power line and the analog temperature signal around the logarithmic amplifier at a sampling rate higher than the Nyquist frequency; The original analog current signal and analog temperature signal are converted from analog to digital respectively to obtain the original digital current signal sequence and the digital temperature signal sequence. The original digital current signal sequence and the digital temperature signal sequence are combined to construct a multidimensional signal vector; A matrix multiplication operation is performed between the multidimensional signal vector and the pre-generated block diagonal compressed sensing matrix to generate a hybrid observation vector.
3. The power data acquisition method based on a logarithmic amplifier as described in claim 2, characterized in that: The process of performing high-speed analog-to-digital conversion on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence, and then storing the discrete digital signal sequence in a priority buffer area, is detailed below. The temperature-compensated compressed voltage signal is analyzed in real time through a transient feature detection mechanism to dynamically obtain the optimal sampling rate parameter; Based on the optimal sampling rate parameter, the analog-to-digital converter is controlled to perform incremental modulation on the temperature-compensated compressed voltage signal to obtain a discrete digital signal sequence; A multi-priority cache management strategy is used to store discrete digital signal sequences into a priority cache area.
4. The power data acquisition method based on a logarithmic amplifier as described in claim 3, characterized in that: The steps for extracting real-time signal gradients from discrete digital signal sequences in the priority buffer region and calculating the average gradient of the real-time signal gradient within a preset time window as the steady-state reference gradient are as follows. Read the discrete digital signal sequence from the priority buffer area and obtain the real-time signal gradient of the discrete digital signal sequence; Variational mode decomposition of real-time signal gradients yields multiple essential mode functions; Sparse encoding is performed on multiple essential mode functions to select gradient components that meet the sparse energy threshold. The gradient components are used to calculate the weighted average gradient value within a preset time window as the steady-state reference gradient.
5. The power data acquisition method based on a logarithmic amplifier as described in claim 4, characterized in that: The specific steps for performing a difference operation between the real-time signal gradient and the steady-state reference gradient to generate a difference value sequence are as follows. Calculate the reference difference between the real-time signal gradient and the steady-state reference gradient; The baseline difference value is processed using the stochastic differential probability method to obtain a probability-transformed difference sequence; Fourier spectrum filtering is applied to the probability transform difference sequence to generate a difference value sequence.
6. The power data acquisition method based on a logarithmic amplifier as described in claim 5, characterized in that: The step of comparing the difference values in the difference value sequence with the first and second discrimination thresholds to obtain the transient data packet is as follows: The differential value sequence is monitored. When the differential value in the differential value sequence is continuously lower than the first discrimination threshold, it is determined that the current state is in power frequency steady state mode, and the optimal low sampling rate is obtained based on the steady state reference gradient to collect power data. When the difference value in the difference value sequence exceeds the second discrimination threshold, it is determined to be a transient event mode, and a high sampling rate is maintained and the buffer is locked to generate a transient data packet.
7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the power data acquisition method based on a logarithmic amplifier as described in any one of claims 1 to 6.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, it implements the steps of the power data acquisition method based on a logarithmic amplifier as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Optical fiber temperature measurement signal compensation method and system based on deep learning
CN121117577A
Detection logarithm video amplifier
CN206164484U