PENet+: A Lightweight Residual Transformer Framework for Efficient Image Steganalysis
Published 9 Jun 2026 in cs.CV | (2606.10939v1)
Abstract: Image steganalysis, the detection of hidden information embedded in digital images, is a core component of modern cybersecurity and digital forensics. Recent residual Transformer architectures, such as the Pixel-Difference-Convolution and Enhanced-Transformer-Network (PENet) [1], achieve strong detection accuracy, but their computational and memory demands hinder deployment in resource-constrained settings. We present PENet+, a lightweight steganalysis framework that preserves PENet's discriminative structure while substantially improving efficiency. Rather than redesigning or compressing the attention blocks, we retain PENet's self-attention topology for reproducibility and add a classifier-streamlining stage that progressively narrows the SPP-to-FC1 input channels (SPP: spatial pyramid pooling; FC1: first fully connected layer), yielding large reductions in parameters and FLOPs with negligible accuracy loss. We further refine the high-pass-filter (HPF) stem with an activation-aware mechanism that aggregates HPF responses early and selects a balanced SRM-Gabor top-K subset, and we replace PENet's backbone with a MobileNetV2-style inverted residual network. A balanced configuration with K=31 filters (16 Gabor + 15 SRM) matches or surpasses heavier settings at lower compute. Finally, we motivate PReLU from a steganalysis standpoint, arguing that preserving negative responses helps capture weak stego cues that ReLU suppresses. On a disjoint ALASKA2 JPEG QF90 protocol at 512x512 resolution (5,000 cover images for training, validation, and internal testing; a separate 19,000-cover evaluation set), PENet+ achieves up to 45.5% fewer parameters and about 97% fewer FLOPs than the re-evaluated PENet baseline, offering a computationally efficient direction for resource-constrained steganalysis. Device-level latency and power measurements remain future work.
The paper introduces PENet+, a lightweight residual Transformer that combines activation-aware selection of 31 fixed high-pass filters, inverted residual blocks, classifier compression, and PReLU activations to reduce computational demands.
PENet+ achieves up to 97% fewer FLOPs and 45.5% fewer parameters than the re-evaluated PENet baseline, while PENet+–L reaches 0.9481 accuracy on nsF5 at 0.4 bpc and PENet+–S outperforms SRNet with only 2.12 GFLOPs.
The results show that accuracy-per-FLOP is a practical metric for resource-constrained steganalysis, although on-device latency, broader embedding methods, multiple JPEG quality factors, and the preserved quadratic attention cost remain open concerns.
Motivation and problem setting
PENet+ addresses the deployment cost of Transformer-based image steganalyzers. The starting point is PENet, a residual Transformer that combines pixel-difference convolution (PDConv) with an enhanced multi-head self-attention (MHSA) module and selective pooling, which achieves strong accuracy on ALASKA2 but carries a substantial computational burden at 512×512 resolution: 16.16M parameters and 67.48 GFLOPs per forward pass. The authors identify four sources of inefficiency in existing steganalyzers: fixed high-pass filter (HPF) banks with no selection, depthwise-only PDConv stacks lacking pointwise channel mixing, full-resolution MHSA whose cost grows quadratically with token count, and oversized classifier bottlenecks after spatial pyramid pooling (SPP). Notably, roughly half of PENet's parameters reside in the MHSA block and about a third in the classifier, while profiling shows that convolutional backbone plus attention account for over 95% of total FLOPs.
The design philosophy is deliberately conservative: rather than compressing or redesigning the attention blocks, PENet+ preserves PENet's MHSA topology for reproducibility and concentrates efficiency gains on three other components—HPF selection, backbone replacement, and classifier streamlining.
Method
Activation-aware HPF selection. Starting from a 62-filter bank (30 SRM, 32 Gabor), the framework selects a balanced top-K subset via a shared balanced selector algorithm that preserves SRM/Gabor ratio and Gabor orientation–phase coverage. Two modes are studied: v2, a non-learning pre-selection based on warm-up activation energies measured on the Y channel; and v3 (default), a learnable selector consisting of a two-layer MLP over globally pooled HPF responses trained with classification loss plus an ℓ1 sparsity penalty. Unlike PENet's learnable-HPF variant—which reportedly fails to converge beyond random guessing—PENet+ never updates filter kernels, only learns which fixed filters to keep, yielding stable convergence. A sweep of K∈{15,31,48} shows K=31 (16 Gabor + 15 SRM) matches or exceeds heavier configurations; critically, activation-based selection outperforms random subsets under the same budget by +0.0122 accuracy at K=15 and +0.0162 at K=31 for [email protected] bpc, confirming the ranking is informative rather than merely a pruning effect.
Inverted residual backbone. PDConv stacks are replaced with MobileNetV2-style inverted residual (IR) blocks (expand–depthwise–project). Because channel mixing moves to cheap 1×1 layers and spatial filtering to depthwise convolutions, the spatial cost drops by roughly a factor of C at high resolutions; empirically this yields about 60% FLOPs reduction in the high-resolution stages. Squeeze-and-excitation and DropPath are omitted to keep the critical path short on edge devices.
Classifier streamlining. The SPP→FC1 input dimension Din=C⋅21 is narrowed from PENet's 5376 (K0) to 2688/1344/672 across the L/M/S variants, reducing FC1 parameters by roughly 4× to 16× (e.g., 5.5M → 0.34M for the smallest variant).
Attention and activations. The MHSA topology—including scaled dot-product attention with learned bias, residual connection, and query-side tokenization—is kept intact; only the K/V branches are reimplemented as lightweight IR blocks with narrower channels. On activations, PReLU with per-channel learnable slopes consistently outperforms ReLU, ReLU6, LeakyReLU, and SiLU. The paper argues from a steganalysis standpoint that preserving weak negative responses captures stego cues that ReLU suppresses; the gain is most pronounced in compact classifiers (A3→A4 improves [email protected] accuracy from 0.9278 to 0.9481 at unchanged FLOPs).
Experimental results
The evaluation uses a disjoint ALASKA2 JPEG QF90 protocol: 5,000 covers split into 4,000 train / 500 validation / 500 internal test, with a separate 19,000-cover held-out evaluation set, covering nsF5, J-UNIWARD, and UERD at 0.2 and 0.4 bpc. Key results are reported as mean(std) over K1 seeds.
The headline claim is a 45.5% parameter reduction and ~97% FLOPs reduction relative to the re-evaluated PENet baseline. Against efficient baselines retrained under the same protocol, PENet+–S attains higher accuracy than SRNet (0.9070 vs. 0.8803 on [email protected]) and ZhuNet (0.7266) with fewer FLOPs than either (2.12G vs. 24.29G and 5.03G), though it has more parameters—a trade-off the authors explicitly frame as accuracy-per-FLOP rather than parameter efficiency.
Two caveats deserve emphasis. First, the comparison to the original PENet numbers is not apples-to-apples: PENet's published result (80.03% on CMD-C-HILL TIFF) uses a different embedding scheme, so all comparisons here rest on the authors' own re-trained ReLU baseline, which performs unevenly across embedders (e.g., only 0.5701 on [email protected]). Second, the stepwise ablation A1→A4 is acknowledged to be progressive rather than single-factor: the A2→A3 transition changes both the backbone operator and channel width simultaneously, so the isolated contribution of IR blocks cannot be read off directly.
Selector diagnostics indicate the choice between v2 and v3 depends on classifier width and embedding method: v2 is more stable at small K5, while v3 benefits mid-width settings for J-UNIWARD/UERD (e.g., 0.9356 vs. 0.9038 at K6=1344). Class-agnostic HPF activation-energy visualizations further show that PENet+ variants concentrate responses around true modification regions more tightly than the original PENet, suggesting the efficiency-oriented design also sharpens residual saliency.
At K7 center crops, PENet+ again dominates the re-evaluated baseline on J-UNIWARD and UERD (e.g., 0.8629 vs. 0.7089 at 0.4 bpc) with 0.33–1.26 GFLOPs versus 16.7G, though the authors note this is a controlled stress test rather than a native-resolution benchmark.
Limitations and open questions
The paper is explicit about several boundaries. Device-level latency, memory, and power measurements are not provided; efficiency claims rest entirely on parameter/FLOPs counts, which may not translate directly to edge-hardware speedups given the preserved quadratic MHSA. The evaluation covers a single quality factor (QF90) and three classical JPEG embedders, leaving generalization to adaptive or adversarial embedding open. The ablation does not isolate the IR backbone's individual contribution, and the advantage of PReLU is argued mechanistically rather than analyzed quantitatively. Finally, the re-trained ReLU baseline's weak performance on some embedders means the magnitude of the accuracy-preservation claim depends on baseline strength.
Conclusion
PENet+ demonstrates that a residual Transformer steganalyzer can shed most of its forward computation—97% FLOPs and 45.5% parameters—without redesigning its attention mechanism, by combining activation-aware balanced HPF selection (K8), an inverted-residual backbone, classifier streamlining, and PReLU activations. The results position accuracy-per-FLOP, rather than minimal parameter count, as the relevant metric for resource-constrained steganalysis, while leaving on-device validation and broader embedding coverage as concrete open questions.