Infrared image compression method based on Mama linear recursive scanning

By adopting an infrared image compression method based on Mamba linear recursive scanning, combined with a thermodynamic state space module and a biomimetic pulse decoder, the problems of physical dimension inversion distortion and loss of weak thermal texture in existing infrared image compression technologies are solved. Real-time high-fidelity compression at the edge is achieved, which is suitable for fault diagnosis of power equipment and industrial thermal energy process control.

CN121961828APending Publication Date: 2026-05-01BEIJING UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
BEIJING UNIV OF TECH
Filing Date
2026-01-18
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing infrared image compression technologies cannot simultaneously meet the requirements of lossless inversion of physical dimensions, high-fidelity preservation of weak thermal textures, and real-time edge computing under the same architecture. In particular, traditional methods have not effectively solved the problem of detail loss in high-frequency edges and low-contrast areas.

Method used

An infrared image compression method based on Mamba linear recursive scanning is adopted. Through global physical parameter locking and normalization preprocessing, combined with thermodynamic state space module, subpixel convolution upsampling and biomimetic pulse decoder, adaptive calculation step size and global thermal gradient perception are achieved, which enhances the preservation of weak texture features and avoids artifacts through subpixel convolution, and supports end-to-end physical calibration.

Benefits of technology

It achieves lossless dimensional restoration from normalized data to the physical radiation matrix, ensuring that the reconstructed image meets industrial-grade quantitative temperature measurement accuracy, reducing inference latency and memory usage, and providing a real-time, high-fidelity infrared image compression solution for resource-constrained edge devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121961828A_ABST
    Figure CN121961828A_ABST
Patent Text Reader

Abstract

The invention discloses an infrared image compression method based on Mama linear recursive scanning, and belongs to the crossing field of computer vision image processing and infrared thermal imaging technologies. According to the method, an end-to-end deep learning framework is adopted, and the method comprises the steps that firstly, global physical parameter locking and normalization preprocessing are carried out; and 2, feature extraction and coding based on a thermodynamic state space module. And 3, carrying out super-prior feature analysis and probability modeling. And 4, entropy parameter prediction based on the bionic pulse decoder. And step 5, performing sub-pixel resolution reconstruction and physical field inversion. According to the method, through a full-process penetration and linear inversion mechanism of global gain and offset factors, based on the linear complexity advantage of the Mama architecture, and in combination with a four-way scanning causal deviation elimination and sub-pixel convolution artifact-free up-sampling strategy, reasoning delay and video memory occupation are remarkably reduced on the basis of ensuring global thermal field topological continuity, and the method has the advantages of high efficiency and high reliability. And a real-time and high-fidelity infrared image compression solution is provided for resource-limited edge end equipment.
Need to check novelty before this filing date? Find Prior Art

Description

An Infrared Image Compression Method Based on Mamba Linear Recursive Scanning Technical Field

[0001] This invention belongs to the interdisciplinary field of computer vision image processing and infrared thermal imaging technology, and specifically relates to an end-to-end infrared image compression method based on Mamba linear recursive scanning architecture, thermodynamic state space module, subpixel convolutional upsampling and biomimetic pulse decoding. Background Technology

[0002] Infrared thermography, a branch of radiometry, is fundamentally valuable for detecting the infrared radiation flux across an object's surface and using Planck's blackbody radiation law and the Stefan-Boltzmann law to invert the target's absolute temperature field. Unlike visible light images that only record reflectivity, modern uncooled or cooled infrared focal plane arrays (FPAs) output raw data with a high dynamic range of 10-bit to 16-bit, possessing clearly defined physical dimensions. This data not only carries information about the scene's geometry but also contains differences in radiant energy at the nanowatt (nW) level, providing a foundation for quantitative analysis in fields such as power equipment fault diagnosis, industrial thermal process control, and medical thermal tomography.

[0003] However, with the increasing resolution of infrared detectors, the large amount of raw radiation data poses a significant challenge to the transmission bandwidth and storage space at the edge. Traditional general image compression standards (such as JPEG, JPEG2000, HEVC / H.265, etc.) are mainly designed based on the visual perception model of the human visual system (HVS), tending to discard high-frequency components that are not sensitive to the human eye, and forcibly quantizing and truncating high-bit-depth data to an 8-bit color space. Although this visually lossy processing can achieve a high compression ratio, it physically disrupts the linear mapping relationship between pixel grayscale values ​​and radiance. The resulting quantization noise and block effects may be visually imperceptible, but in temperature inversion algorithms, they are amplified into measurement errors of several degrees Celsius or even tens of degrees Celsius, causing the reconstructed thermal images to fail to meet the accuracy requirements of industrial-grade measurements.

[0004] In recent years, deep learning-based image compression methods, such as variational autoencoders (VAEs), have performed excellently on natural images, but their direct transfer to the field of infrared thermal imaging still faces significant architectural shortcomings.

[0005] Convolutional neural network (CNN)-based solutions are limited by their local receptive field, making it difficult to capture the global background thermal distribution and slowly changing temperature drift phenomena commonly found in infrared images. This leads to distortion of the low-frequency reference plane in the reconstructed thermal map. While the VisionTransformer (ViT) architecture possesses global modeling capabilities, the computational complexity of its core self-attention mechanism increases quadratically with image resolution, significantly consuming GPU memory and computing power. This makes it difficult to implement real-time inference on power-constrained handheld thermal imagers or drone payloads located close to the edge. Furthermore, existing image compression deep networks typically employ uniform processing logic across all image regions, lacking the ability to perceive infrared thermodynamic features. This results in significant computational resource consumption in background regions with gentle temperatures, while insufficient sampling occurs at fault edges or in areas with sharp spatial thermal gradients or small temperature differences, leading to the loss of crucial diagnostic information.

[0006] The emergence of Structured State Space Models (SSLAM) and its variant, the Mamba deep network architecture, has provided a new opportunity to resolve the aforementioned contradictions. Mamba achieves long-range dependency modeling with linear computational complexity O(N) through a selective scanning mechanism, theoretically combining the inference efficiency of CNNs with the global perspective of Transformers. However, the original Mamba model was initially designed to process one-dimensional temporal signals, and its scanning method is typically fixed, lacking an adaptive adjustment mechanism for two-dimensional thermal field distributions. For infrared images, if the recursive step size of the state space cannot be dynamically adjusted based on local thermal entropy changes, accurate capture of high-frequency thermal textures at finite bitrates is impossible.

[0007] In summary, existing technologies cannot simultaneously meet the triple requirements of lossless inversion of physical dimensions, high-fidelity preservation of subtle thermal textures, and real-time edge computing under the same architecture. There is an urgent need for a novel infrared image compression method that can deeply integrate thermodynamic prior knowledge into state-space recursive logic and support end-to-end physical calibration. Summary of the Invention

[0008] The purpose of this invention is to overcome the shortcomings of existing infrared image compression technologies, such as physical dimension inversion distortion, loss of weak thermal textures, and low edge inference efficiency, and to provide an infrared image compression method based on Mamba linear recursive scanning.

[0009] To achieve the above objectives, the present invention provides the following technical solution: an infrared image compression method based on Mamba linear recursive scanning, which employs an end-to-end deep learning framework and specifically includes the following processing flow:

[0010] Step 1: Global physics parameter locking and normalization preprocessing.

[0011] First, iterate through the original infrared radiation data matrix. Calculate and lock the global offset factor (minimum value) and the global gain factor (the difference between the maximum and minimum values). Based on the formula... The original data is linearly normalized to map the physical radiation values ​​with a wide dynamic range to the [0,1] interval, thus establishing a benchmark for the thermal field distribution pattern learned by the network.

[0012] Step 2: Feature extraction and encoding based on thermodynamic state-space module (TSSMLayer).

[0013] The normalized heatmap is input into a thermodynamic analysis transformation network, which consists of four cascaded convolutional downsampling units and thermodynamic state-space modules (TSSMLayer). In each TSSMLayer, the following operations are performed:

[0014] Gradient-gated generation: The horizontal gradients of the feature maps are calculated using the built-in 3×3 Sobel operator. and vertical gradient The gradient magnitude M is obtained by using the Gaussian radial basis function. The gradient magnitude is nonlinearly mapped to a gated signal, where The learnable threshold.

[0015] Step-size adaptive modulation: The gate signal is concatenated with the input features, and the time step parameters are generated through a linear transformation layer and a Softplus activation function. This enables physical sensing modulation of the Mamba discretization parameters.

[0016] Four-dimensional scanning recursion: The two-dimensional feature map is unfolded into a sequence of four dimensions: forward, backward, transposed forward, and transposed backward. The generated sequence is then used... The parameter-controlled state-space model is recursively applied in parallel, and finally the features are merged to aggregate omnidirectional radiation context information.

[0017] Step 3: Prior feature analysis and probabilistic modeling.

[0018] A super-prior analysis transform network is constructed, consisting of three convolutional layers. The first layer uses a 3×3 convolutional kernel to preserve details, while the second and third layers use a 5×5 large convolutional kernel combined with a downsampling operation with a stride of 2 to capture wide-area context. The extracted super-prior features are scalar quantized and arithmetic encoded to generate a super-prior feature bitstream, which serves as side-channel information for the decoder to estimate the probability distribution (mean and variance) of the master latent features.

[0019] Step 4: Entropy parameter prediction based on the bionic pulse decoder (Spiking Decoder).

[0020] In the advanced prior synthesis transform network at the decoding end, a biomimetic pulse decoder is introduced to enhance weak texture features. The processing logic of this module is as follows:

[0021] Texture current calculation: The absolute difference between the feature map in the horizontal and vertical directions is calculated using a tensor shift (Roll) operation to generate a current representing the local texture intensity. .

[0022] LIF neuron integral: Using the Leaky Integrate-and-Fire model, the formula is applied. Accumulated film potential to simulate the integral effect of weak thermal texture energy.

[0023] Soft pulse weighting: When the membrane potential exceeds the threshold, a continuously differentiable soft pulse signal S is generated using the Sigmoid function, and this signal is used as an attention mask to weight and enhance the features. This allows key high-frequency details to be preserved in the decoding parameter prediction.

[0024] Step 5: Subpixel resolution reconstruction and physical field inversion.

[0025] The predicted entropy parameters are used to perform arithmetic decoding of the master latent features, which are then input into a thermodynamic synthesis transform network. This network adopts a four-level cascaded architecture, with each level containing a sub-pixel convolutional upsampling module and a thermodynamic state space module.

[0026] Subpixel convolution: Expands the feature channels to the target number of channels through convolution. The algorithm uses a periodic rearrangement algorithm (r is the upsampling factor) to fold the depth information of the channel dimension to the spatial dimension, thereby achieving non-interpolation resolution reconstruction and avoiding checkerboard artifacts.

[0027] Physical inversion: After noise is filtered out by the refinement module, the global gain factor Gain and global offset factor Offset in the bitstream are called to perform the linear inverse transform formula. The normalized thermal map is strictly clamped back to the effective temperature measurement range of the infrared detector, and restored to a radiation measurement matrix with clear physical dimensions.

[0028] The beneficial effects of this invention are:

[0029] This invention achieves lossless dimensional restoration from normalized data to the physical radiation matrix through a full-process integration of global gain and offset factors and a linear inversion mechanism, ensuring that the reconstructed image meets industrial-grade quantitative temperature measurement accuracy. It innovatively integrates thermodynamic gradient gating and biomimetic pulse decoding technologies, adaptively allocating the calculation step size based on the local thermal gradient and accumulating weak texture energy, effectively overcoming the detail loss problem in high-frequency edges and low-contrast regions in traditional methods. Simultaneously, leveraging the linear complexity advantage of the Mamba architecture, combined with four-way scanning to eliminate causal bias and a sub-pixel convolution artifact-free upsampling strategy, it significantly reduces inference latency and memory usage while ensuring the continuity of the global thermal field topology, providing a real-time, high-fidelity infrared image compression solution for resource-constrained edge devices. Attached Figure Description

[0030] Figure 1 shows the infrared image compression encoding and decoding network architecture based on Mamba linear recursive scanning.

[0031] Figure 2 shows the structure of the thermodynamic state space module (TSSMLayer).

[0032] Figure 3 is a schematic diagram of the channel attention module structure.

[0033] Figure 4 shows the structure of the biomimetic pulse decoder. Detailed Implementation

[0034] In the specific implementation process, the input data stream is the raw infrared data acquired by the infrared camera. This data is defined as follows: Two-dimensional matrix of resolution , Each value represents the radiation intensity at the corresponding spatial location. In this embodiment, the processed data has a bit depth of 16 bits.

[0035] In order to map this spatial thermal radiation data to a numerical space that a neural network can stably process while preserving its physical reducibility, the method of the present invention performs the following coding steps.

[0036] Encoding Step 1: Statistical Extreme Values ​​and Parameter Locking.

[0037] First, iterate through the entire... Matrix, calculate the minimum value of its elements With the maximum value Then, initialize the global offset factor. and global gain factor These two parameters (Gain, Offset) are cached in 32-bit floating-point format.

[0038] Encoding step 2: Normalization preprocessing of the input image.

[0039] Based on the above parameters (Gain, Offset) Perform normalization calculations:

[0040] ;

[0041] Data Compressing to the [0,1] interval transforms the network's learning object from absolute values ​​to thermal field distribution patterns, reducing the interference of background shifts on training dynamics under different temperature measurement scenarios, while ensuring that accurate physical dimension inversion can be performed in the subsequent recovery phase.

[0042] Encoding Step 3: Thermodynamic Analysis Transformation Network Encoding;

[0043] Preprocessed normalized heatmap The data is fed into a thermodynamic analysis transform network. The encoding end consists of four stacked TSSMLayer layers, each containing downsampling convolutional units and a thermodynamic state space module, and incorporating residual connections and normalization layers to extract semantic representations characterizing the spatial structure of thermal radiation level by level. This step extracts feature representations through a thermodynamic analysis transform network composed of a convolutional downsampling module, a thermodynamic state space module, a channel attention module, and a group normalization module.

[0044] Encoding step 3.1: Convolutional downsampling module;

[0045] This module first reduces the spatial dimensionality of the features using downsampling convolutional units. These units are configured with 3×3 kernels, a stride of 2, and padding of 1. This operation halves both dimensions of the feature map's spatial resolution and expands the number of channels from the input to 128. Here, the convolutional kernel refers to the weight matrix used in the convolution operation, and its size determines the receptive field size; the stride is the distance the kernel slides across the feature map; and padding involves adding zeros to the edges of the feature map to maintain the spatial dimensions of the output feature map.

[0046] Encoding step 3.2: Thermodynamic State Space Module (TSSMLayer);

[0047] The core component of this invention, the thermodynamic state space module, performs adaptive recursive calculations driven by spatial thermal gradients. First, the feature distribution is normalized using the LayerNorm operation. Then, feature abstraction is performed through sub-steps including gradient calculation and gating generation, adaptive generation of time step parameters, four-way scanning, and state updates.

[0048] Encoding step 3.2.1: Gradient calculation and gating generation;

[0049] The gradients of the feature maps in the horizontal direction were calculated using a 3×3 Sobel kernel. and the gradient in the vertical direction The Sobel operator is an edge detection operator that approximates the gradient of the image brightness function using a discrete differential operator. The convolution kernel is defined as follows:

[0050] ;

[0051] Then, the gradient magnitude is calculated. .in It is a small constant used to maintain numerical stability, preventing computational anomalies when the gradient is zero. Amplitude Physically, this directly corresponds to the degree of drastic temperature changes in infrared images.

[0052] In order to convert the unbounded physical gradient The system converts the signals into control signals usable by a neural network by introducing a Gaussian radial basis function for nonlinear mapping to generate gated signals. :

[0053] ;

[0054] in It is a learnable threshold parameter, the center threshold of the gradient magnitude. This formula establishes the following logical relationship: when the local spatial thermal gradient... When it is very large, such as the edge region, The value tends to 0. When the local spatial thermal gradient When the background area is very small, such as a flat background area, The value tends to 1.

[0055] Encoding step 3.2.2: Adaptive generation of time step parameters

[0056] This signal is then directly injected into the time step parameter (Delta) generation network of the linear recursive computation module:

[0057] ;

[0058] Concat, short for Concatenate, represents the operation of concatenating two or more tensors into a larger tensor along a specified dimension. In this implementation, Concat(x, Gate) concatenates the input feature tensor x with the gate signal tensor Gate along the channel dimension. This operation injects spatial gradient information into the feature representation, enabling subsequent calculations to be aware of the distribution of spatial thermal gradients. Linear represents a linear transformation layer, also known as a fully connected layer, mathematically expressed as y = Wx + b, where W represents a learnable weight matrix and b represents a learnable bias vector. This operation learns the weight matrix and extracts a combined representation of the input features and gradient gating information, providing input for the prediction of time step parameters. Softplus is a smooth activation function, mathematically expressed as Softplus(x) = ln(1 + exp(x)), where ln represents the natural logarithm. The output of the Softplus function is always positive, approximating x when x > 0 and approximating 0 when x < 0. In this implementation, the Softplus function converts the output of the linear layer into a time step parameter Δ, ensuring that the value of Δ is always positive and within a reasonable range.

[0059] In summary, the generation process of the time step parameter Δ is as follows: first, the input feature x is concatenated with the gradient gate in the channel dimension; then, the combined features are extracted through linear transformation; and finally, the output is mapped to the positive range through the Softplus function.

[0060] This design implements an adaptive computation mechanism for spatial thermal gradient guidance: In regions with large spatial thermal gradients, the model generates a smaller step size parameter Δ. A smaller time step means more refined state updates, allowing the model to extract features with higher accuracy, thus capturing and preserving the edge geometry of the thermal target. In regions with smaller spatial thermal gradients, the model generates a larger step size parameter Δ. A larger time step means more coarse state updates, allowing the model to capture the global background temperature distribution with lower computational cost, improving inference efficiency.

[0061] Encoding step 3.2.3: Four-way scan and state update;

[0062] Next, the feature map is first unfolded into a sequence along four directions: forward (top left to bottom right), reverse (bottom right to top left), transposed forward (top left to bottom right after transposition), and transposed reverse (bottom right to top left after transposition). Then, state updates controlled by Δ are achieved through selective scanning, and the feature sequences in the four directions are processed independently. This omnidirectional scanning mechanism simulates the radiation and diffusion characteristics of the thermal field in the medium, enabling any pixel position to perceive the thermal context information of its four neighbors, and constructing a potential representation with a global receptive field and continuous thermal structure.

[0063] To construct a hierarchical representation of thermal radiation features, this invention cascades the convolutional downsampling module described in encoding step 3.1 with the TSSMLayer described in encoding step 3.2 in four stages. The specific configuration of the cascaded structure is as follows: the first to third stages use downsampling convolutions with a stride of 2, and the fourth stage uses convolutions with a stride of 1 to maintain spatial resolution. Within each TSSMLayer, feature transformation is performed in the order of "convolutional downsampling → TSSM feature extraction → residual connection".

[0064] The four-level downsampling operation works in concert to achieve joint optimization of spatial resolution and channel dimension: the first-level downsampling reduces the feature map size from the original (H, W) to At the same time, the input channels were expanded from 1 to 128; the second stage continued to reduce the size. The third level was further compressed to The fourth level maintains the same spatial dimensions and preserves... After four levels of cascaded processing, the channel dimension of the feature tensor stabilizes at 128, and the spatial resolution is compressed to 1 / 8 of the original, forming a compact intermediate representation of [B, 128, H / 8, W / 8]. This intermediate representation significantly reduces subsequent computational complexity and data storage requirements while preserving key thermal radiation structure information.

[0065] Encoding step 3.3: Channel attention module;

[0066] At the end of the encoder, a 3×3 convolutional layer is introduced to expand the number of channels from 128 to 192, followed by a channel attention module. This module first performs global average pooling on the input feature map in spatial dimension, compressing each channel into a scalar value with an output shape of [B, C, 1, 1], where B represents the batch size and C represents the number of channels. Then, the first fully connected layer compresses the number of channels from C to C / r (where r is the compression ratio, with a default value of 16) and applies the ReLU activation function. Next, the second fully connected layer restores the number of channels from C / r to C and applies the Sigmoid activation function, mapping the output to the (0, 1) interval to generate channel attention weights. Finally, the generated weights are multiplied with the input feature map channel by channel, adaptively suppressing invalid channels containing fixed-pattern noise and enhancing effective channels containing important information.

[0067] Encoding step 3.4: Group normalization module;

[0068] Finally, a group normalization module with 8 groups is applied to normalize the features. Group normalization involves dividing the channels into several groups and performing standardization within each group. It is independent of batch size and suitable for small-batch training scenarios. The final output master latent feature y contains highly compressed semantic and thermodynamic structural information. The master latent feature y then enters the quantizer for scalar quantization, converting continuous floating-point values ​​into discrete integer representations. The mathematical expression for scalar quantization is:

[0069] ;

[0070] Here, Round indicates rounding. Quantized features The data is fed into an arithmetic encoder for entropy encoding to generate a feature bitstream of the main latent features.

[0071] Encoding Step 4: Transformation Network Modeling and Encoding Based on Prior Analysis;

[0072] The latent feature y is then fed into a super-prior analysis transform network for probabilistic modeling. This network is used to predict the distribution parameters of the latent feature y, including the mean and variance, thereby improving the efficiency of entropy encoding. The network employs a progressive convolutional downsampling architecture, consisting of three convolutional layers.

[0073] Encoding step 4.1: First convolutional unit;

[0074] The first layer uses a 3×3 convolutional kernel with a stride of 1 and padding of 1, preserving the spatial dimensions of the feature map. It has 192 input channels and 128 output channels. This layer performs initial feature dimension compression, mapping high-dimensional latent features to a lower-dimensional intermediate representation while preserving spatial details. A LeakyReLU activation function is then applied to introduce non-linearity.

[0075] Encoding step 4.2: Second convolutional unit;

[0076] The second layer uses a 5×5 convolutional kernel with a stride of 2 and padding of 2. This operation reduces the spatial resolution of the feature map from H / 8, W / 8 to H / 16, W / 16, while maintaining the number of channels at 128. The larger kernel size captures a wider range of contextual information, and the downsampling operation with a stride of 2 further compresses the data volume. This layer also uses the LeakyReLU activation function.

[0077] Encoding step 4.3: Third convolutional unit;

[0078] The third layer is also configured with a 5×5 convolutional kernel, a stride of 2, and padding of 2. This operation further reduces the spatial resolution of the feature map from H / 16, W / 16 to H / 32, W / 32, while the number of channels remains at 128. After processing by three convolutional units, the shape of the hyper-prior feature z is [B, N, H / 32, W / 32].

[0079] Encoding step 4.4: Quantization and entropy coding;

[0080] The prior feature z then enters the quantizer for scalar quantization, and the quantized feature... The data is fed into an arithmetic encoder for entropy encoding, generating a super-prior feature bitstream. The arithmetic encoder employs an adaptive probability model, allocating code lengths based on the statistical characteristics of the features to achieve efficient lossless compression. The probability model estimates the probability of each symbol's occurrence, and entropy encoding allocates codewords of varying lengths based on symbol probabilities, assigning shorter codewords to symbols with high probabilities and longer codewords to symbols with low probabilities.

[0081] The decoding and thermal radiation data physical reconstruction steps of the infrared image compression method of this invention are the reverse of the encoding process. Its goal is to accurately reconstruct the physical radiation field of the original scene based on restoring the visual morphology of the image. The decoding process first parses the compressed bitstream, separating the main latent feature bitstream and the super-prior feature bitstream. Then, the super-prior synthetic transform network predicts the entropy encoding parameters to guide the arithmetic decoding of the main latent features. Next, the spatial resolution of the feature map is gradually restored through a thermodynamic synthetic transform network. Finally, quantization noise is filtered out by a refinement module, and a linear inverse transform is performed to restore the normalized dimensionless tensor to a radiation matrix with actual physical meaning.

[0082] Decoding Step 1: Decoding of Super-Prior Features and Prediction of Entropy Parameters;

[0083] The decoder first reads the priori feature bitstream from the compressed bitstream. Furthermore, entropy decoding is performed using an arithmetic decoder to recover the prior features. Arithmetic decoding is the inverse process of arithmetic coding, converting a bitstream into discrete quantized values ​​according to the same probability model. The recovered prior features... The shape is (B, N, H / 32, W / 32), where N is 128 representing the channel dimension, and H and W are the height and width of the original input image. Subsequently, the hyper-prior features... It is fed into a priori synthetic transform network, which mainly consists of two bilinear upsampling units and a biomimetic pulse decoder.

[0084] Decoding step 1.1: First upsampling unit;

[0085] The first upsampling unit is configured with bilinear interpolation upsampling at a factor of 2, followed by a 3×3 convolutional kernel with a stride of 1 and padding of 1. This operation increases the spatial resolution of the feature map from (H / 32, W / 32) to (H / 16, W / 16) while maintaining 128 channels. Bilinear interpolation is an image interpolation algorithm that estimates target pixel values ​​by performing linear interpolation in two directions, offering advantages in preserving edge smoothness. The LeakyReLU activation function is then applied.

[0086] Decoding step 1.2: Bionic pulse decoder;

[0087] To further improve compression efficiency and preserve key weak texture details, this implementation employs a biomimetic spiking decoder in the advanced prior synthesis transform network. This unit is constructed by reproducing the high sensitivity of biological vision to transient information changes. Its core advantage lies in its ability to effectively avoid information loss during processing of low-contrast, low-saliency features such as key weak textures while ensuring compression performance, thus laying the foundation for accurate modeling and efficient utilization of subsequent advanced prior information.

[0088] The biomimetic pulse decoder first calculates the local texture intensity of the input features. This is achieved through a tensor shift (Roll) operation, which calculates the absolute difference between the feature maps in the horizontal and vertical directions, and then adds them together to obtain the texture current. :

[0089] ;

[0090] Here, Roll represents a tensor shift operation, shift represents the shift amount, and dim represents the dimension of the shift. This texture current value physically represents the intensity of the texture in a local region.

[0091] Subsequently, the Leaky Integrate-and-Fire (LIF) neuron model was employed. Each neuron maintains a membrane potential state. This state depends on the input current. Integrate and decay over time according to the decay factor τ:

[0092] ;

[0093] Where t represents the discrete time step, with a value range of t∈{1, ..., T}, and τ is the decay factor. For static feature map input, The simulation remains constant across all time steps, simulating continuous texture stimulation.

[0094] When the accumulated membrane potential exceeds a certain threshold At this time, neurons should fire impulses. To ensure the stability of the neural network during the inference phase, this invention employs a soft-spike mechanism. The sigmoid function is used as a continuous approximation of the step function to generate a soft-spike signal S ranging from (0,1).

[0095] ;

[0096] Where k is the slope coefficient, which determines the steepness of the pulse delivery; This is the pulse firing threshold. The generated soft pulse signal S serves as an attention mask, weighting and enhancing the input features:

[0097] ;

[0098] Here, α is the enhancement coefficient, which determines the degree of feature enhancement. The logical significance of this step is that only regions with sufficiently strong texture energy that can stimulate neurons to fire pulses will have their feature values ​​significantly amplified, thereby improving the sensitivity to weak textures in subsequent parameter prediction.

[0099] Decoding step 1.3: Second upsampling unit

[0100] The enhanced features from the pulse encoder are fed into a second upsampling unit, configured with bilinear interpolation upsampling at a factor of 2, followed by a 3×3 convolutional kernel with a stride of 1 and padding of 1. This operation increases the spatial resolution of the feature map from (H / 16, W / 16) to (H / 8, W / 8) while maintaining 128 channels. The LeakyReLU activation function is then applied.

[0101] Finally, the number of output channels is expanded from 128 to 384 through a 1×1 convolutional layer, generating Gaussian distribution parameters, namely scales and mean.

[0102] Scale parameters After adjusting the Softplus activation function and offset, we ensure that it is a positive value:

[0103] ;

[0104] Here, 1e-4 is the offset, which is used to prevent the scale parameter from being too small, which would lead to numerical instability.

[0105] Decoding Step 2: Decoding and Preliminary Reconstruction of Master Latent Features;

[0106] The entropy coding parameters, i.e., the scale parameters, predicted in decoding step 1 are used. Arithmetic decoding of the principal latent features is performed using the mean parameter (means).

[0107] First, based on the scale parameters Constructing an entropy-encoded index:

[0108] ;

[0109] in, This represents the indexing operation, which maps continuous scale parameters to discrete index values ​​for lookup in the probability table. Subsequently, an arithmetic decoder is used to process the master latent feature bitstream. Decode:

[0110] ;

[0111] Here, decompress represents arithmetic decoding. The latent features obtained through decoding... The shape is (B, M, H / 8, W / 8), where M=192 represents the channel dimension. After decoding, for Feature normalization is performed using group normalization:

[0112] ;

[0113] Here, GroupNorm represents the group normalization operation, dividing the channels into 8 groups and standardizing within each group to ensure the data distribution has zero mean and unit variance. Then, the channel attention module is applied to... Enhance it while keeping the spatial dimensions unchanged.

[0114] Decoding Step 3: Decoding the thermodynamic synthesis transformation network;

[0115] As shown in Figure 1, in order to extract potential features from low resolution To restore high-resolution reconstructed infrared images, this invention designs a thermodynamic synthesis transformation network. This process is the inverse of the thermodynamic analysis transformation network at the encoding end, aiming to progressively restore the spatial resolution of features and reconstruct the thermal radiation field.

[0116] The data stream first undergoes feature standardization via a group normalization module, followed by adaptive adjustment of feature channel weights through a channel attention module to enhance effective information. The processed features then enter a four-stage stacked upsampling structure, with each stage containing a convolutional layer, a sub-pixel convolutional module, and an inverse thermodynamic state space module. Finally, the feature maps undergo final optimization via a refinement and noise suppression module.

[0117] Decoding step 3.1: Subpixel convolutional upsampling module;

[0118] In each cascaded structure, features first enter the subpixel convolutional upsampling module. This module consists of a 3×3 convolutional layer and a subpixel convolutional operation, and resolution reconstruction is achieved through a periodic rearrangement algorithm.

[0119] First, a 3×3 convolution kernel with a stride of 1 and padding of 1 is used to perform a convolution mapping operation on the input features. This operation expands the number of feature channels to r² times the target number of channels, where r is the upsampling factor. Subsequently, a sub-pixel convolution operation is performed. This operation uses a periodic rearrangement algorithm to orderly fold the depth information of the channel dimension into the breadth information of the spatial dimension. Specifically, the expanded feature channels are rearranged according to a preset pattern, converting the information originally distributed in the channel dimension into a pixel distribution in the spatial dimension, thereby achieving resolution reconstruction. In this process, the channel dimension of the feature map is reduced to the target number of channels, while the spatial resolution is expanded to r times the original size.

[0120] This non-interpolation upsampling mechanism ensures that the generated high-resolution pixels are directly derived from the ordered projection of high-dimensional features, rather than from mathematical estimations based on neighboring pixels. For infrared thermal images, this design avoids the checkerboard artifact problem produced by traditional bilinear or bicubic interpolation algorithms at the algorithmic level, eliminates spurious periodic temperature ripples that may occur in the subsequent temperature inversion process, and guarantees the physical authenticity of the thermal field distribution and the accuracy of the measurement.

[0121] Decoding step 3.2: Thermodynamic state space module;

[0122] Although the rearranged feature map has improved resolution, it may contain local discontinuities. Next, the feature map is input into the thermodynamic state-space module. This process is consistent with the encoding step 3.2 and will be briefly described below.

[0123] This module first normalizes the feature distribution using LayerNorm, then calculates spatial gradient gating to generate an adaptive time step parameter Δ. Gradient gating uses the Sobel operator to calculate the horizontal gradient Gx and vertical gradient Gy, calculates the gradient magnitude M, and generates the gate signal Gate using the Gaussian radial basis function. The time step parameter Δ is generated by a linear transformation and the Softplus function. Subsequently, the feature map is unfolded into a sequence in four directions: forward, backward, transposed forward, and transposed backward. Multi-directional recursion is then performed using a state-space model controlled by Δ. This operation leverages the global receptive field of the state-space model to simulate the physical process of heat conduction, fusing the rearranged independent pixels into a continuous thermal flow field, ensuring that the reconstructed temperature distribution conforms to thermodynamic smoothness constraints.

[0124] To construct a feature reconstruction mechanism symmetrical to the encoding end, this invention designs a four-level cascaded inverse transform architecture to achieve gradual recovery from a compact latent representation to a high-resolution thermal radiation field. This cascaded structure is organized according to specific channel dimension and resolution variation strategies, based on the sub-pixel convolutional upsampling module described in decoding step 3.1 and the inverse thermodynamic state space module described in decoding step 3.2.

[0125] Four levels of upsampling work together to achieve joint optimization of spatial resolution and channel dimension: the first level expands the feature map size from H / 8, W / 8 to H / 4, W / 4, while compressing the input channels from 192 to 128; the second level restores the size to H / 2, W / 2, while maintaining the channel dimension at 128; the third level further restores it to H, W; and the fourth level restores it to the original (H, W) resolution, while reducing the number of channels from 128 to 64. After these four cascaded processes, the shape of the feature tensor gradually transforms from [B, 192, H / 8, W / 8] to [B, 64, H, W], resulting in a high-resolution feature reconstruction. This reconstruction mechanism, while restoring the original spatial resolution, effectively suppresses jagged edges and quantization noise that may occur during upsampling through the synergistic effect of residual connections and normalization within the TSSMLayer module, laying the foundation for the final high-quality physical reconstruction.

[0126] Decoding Step 3.3: Refinement and Noise Suppression Module

[0127] After multiple upsampling operations, the feature map is restored to its original resolution (H, W). To further eliminate high-frequency noise introduced during the quantization process and the inherent fixed-mode noise of the detector, the feature map is then processed by the refinement module.

[0128] Decoding step 3.3.1: Depthwise separable convolution operation. The refinement module first uses a 3×3 convolution kernel with a stride of 1 and padding of 1 to map the feature map from 64 channels to 64. Then, the LeakyReLU activation function is applied to introduce non-linearity.

[0129] Decoding Step 3.3.2: Channel Attention Enhancement Operation. The channel attention module is applied to calculate the global energy of each feature channel, generating channel attention weights. This step allows the network to automatically identify and suppress anomalous channels containing stripe noise or dead pixel features, retaining only channels containing valid thermal radiation information.

[0130] Decoding step 3.3.3: Step-by-step convolutional mapping operation. The refinement module then progressively reduces the feature dimension through two convolutional layers, ultimately mapping to a single-channel output: The first convolutional layer is configured with a 1×1 kernel, reducing the number of channels from 64 to 32, followed by the application of the LeakyReLU activation function. The second convolutional layer is configured with a 3×3 kernel, a stride of 1, and padding of 1, reducing the number of channels from 32 to 1. The output... The normalized heatmap has a value range in the interval [0, 1] and a shape of (B, 1, H, W).

[0131] Decoding Step 4: Total Radiation Physics Inversion;

[0132] The global gain factor Gain and global offset factor Offset extracted during the encoding step are used to normalize the heatmap. Perform a linear inverse transformation to restore the dimensionless tensor to a radiation measurement matrix with physical dimensions.

[0133] The formula for calculating the inverse linear transform is:

[0134] ;

[0135] in, The reconstructed physical radiation matrix is ​​of shape (B, 1, H, W) and its values ​​have definite physical units. This represents a normalized heatmap with values ​​ranging from [0, 1]. `Gain` is used to linearly map the normalized values ​​back to physical dimensions. `Offset` is used to adjust the physical reference values. `Clamp` is a truncation function used to restrict the tensor values ​​to a specified range. and These represent the effective lower and upper temperature limits of the infrared detector, such as -20℃ and 550℃, respectively. This step maps the values ​​in the [0, 1] interval back to their original physical dimensions, and the output is... More than just a visual grayscale image, it's related to the original input. A physically equivalent radiation measurement matrix can be directly used for power fault diagnosis or industrial temperature analysis, thus realizing a complete technical closed loop.

Claims

1. An infrared image compression method based on Mamba linear recursive scanning, characterized in that: This method employs an end-to-end deep learning framework, specifically including the following processing steps: Step 1: Global physical parameter locking and normalization preprocessing; First, traverse the original infrared radiation data matrix. Step 1: Statistically calculate and lock the minimum value of the global offset factor Offset and the difference between the maximum and minimum values ​​of the global gain factor Gain; Step 2: Feature extraction and encoding based on the thermodynamic state space module TSSMLayer; Input the normalized heatmap into the thermodynamic analysis transformation network, which consists of four cascaded convolutional downsampling units and the thermodynamic state space module TSSMLayer; Step 3: Super-prior feature analysis and probabilistic modeling; Construct a super-prior analysis transformation network, which consists of three layers of convolutional units; The first layer uses a 3×3 convolutional kernel to preserve details, and the second and third layers use a 5×5 large convolutional kernel combined with a downsampling operation with a stride of 2 to capture the wide-area context; The extracted prior features are scalar quantized and arithmetic encoded to generate a prior feature bitstream, which serves as side-channel information for estimating the probability distribution of the master latent features at the decoding end. Step four: Entropy parameter prediction based on a biomimetic pulse decoder; a biomimetic pulse decoder is introduced into the prior synthesis transform network at the decoding end to enhance weak texture features. Step five: Subpixel resolution reconstruction and physical field inversion; the predicted entropy parameters are used to perform arithmetic decoding on the master latent features and input into the thermodynamic synthesis transform network; this network adopts a four-level cascaded architecture, each level containing a subpixel convolution upsampling module and a thermodynamic state space module; subpixel convolution: expands the feature channels to the target number of channels through convolution. The upsampling factor is r, where r is the upsampling factor. A periodic rearrangement algorithm is used to fold the depth information from the channel dimension to the spatial dimension, achieving non-interpolated resolution reconstruction and avoiding checkerboard artifacts. Physical inversion: After noise is filtered out by the refinement module, the global gain factor Gain and global offset factor Offset in the bitstream are called to execute the linear inverse transform formula. The normalized thermal map is strictly clamped back to the effective temperature measurement range of the infrared detector, and restored to a radiation measurement matrix with clear physical dimensions.

2. The infrared image compression method based on Mamba linear recursive scanning according to claim 1, characterized in that: Step 1, according to the formula The original data is linearly normalized to map the physical radiation values ​​with a wide dynamic range to the [0,1] interval, thus establishing a benchmark for the thermal field distribution pattern learned by the network.

3. The infrared image compression method based on Mamba linear recursive scanning according to claim 1, characterized in that: In step two, the following operations are performed in each TSSMLayer: Gradient gating generation: The horizontal gradients of the feature maps are calculated using the built-in 3×3 Sobel operator. and vertical gradient The gradient magnitude M is obtained; the Gaussian radial basis function is used to obtain the gradient magnitude M. The gradient magnitude is nonlinearly mapped to a gated signal, where Learnable threshold; adaptive step size modulation: The gate signal (Gate) is concatenated with the input features, and the time step parameters are generated through a linear transformation layer and a Softplus activation function. This enables physical sensing modulation of Mamba discretization parameters; four-dimensional scanning recursion: the two-dimensional feature map is unfolded into a sequence of four dimensions: forward, backward, transposed forward, and transposed backward, and the generated sequence is used... The parameter-controlled state-space model is recursively applied in parallel, and finally the features are merged to aggregate omnidirectional radiation context information.

4. The infrared image compression method based on Mamba linear recursive scanning according to claim 1, characterized in that: In step three: the module's processing logic is as follows: Texture current calculation: the absolute difference between the feature map in the horizontal and vertical directions is calculated through tensor displacement Roll operations to generate a current representing the local texture intensity. LIF neuron integral: Using the Leaky Integrate-and-Fire model, the formula is... Accumulated membrane potential simulates the integral effect of weak thermal texture energy; soft pulse weighting: when the membrane potential exceeds a threshold, a continuously differentiable soft pulse signal S is generated using the Sigmoid function, and this signal is used as an attention mask to weight and enhance the features. This preserves key high-frequency details in the decoding parameter prediction.

5. The infrared image compression method based on Mamba linear recursive scanning according to claim 1, characterized in that: The input data stream is the raw infrared data acquired by the infrared camera; this raw infrared data is defined as... Two-dimensional matrix of resolution , Each value represents the radiation intensity at the corresponding spatial location.