Manuscript Offprint
arXiv:2610.41310STAR-FER: Adaptive Selective Restoration for Edge-Based Low-Resolution Facial Expression Recognition
ZhongYang Wu, ZhenFeng Gan, Di Zhao, XiaoJun Zhu, and HouDe Liu
Abstract—Variable interaction distances continuously degrade facial resolution in edge-based affective interaction, making low-resolution facial expression recognition (FER) difficult under limited computation. Full-face image or feature restoration incurs substantial overhead, whereas lightweight recognition pipelines may miss local cues that remain discriminative after degradation. We propose STAR-FER, a scale-and-task-adaptive selective restoration framework that balances recognition performance and resource constraints. A lightweight image-scale conditioned Gate jointly predicts a pixel-wise spatial ranking and a continuous restoration budget, then applies exact-support projection to obtain an input-dependent free-form mask. The mask-conditioned restorer retains complete facial context while concentrating sparse restoration and residual insertion on the selected support. Across seven degradation scales from ×2 to ×8 on the complete RAF-DB test set, STAR-FER achieves 80.92% mean accuracy and 71.64% Macro-F1, improving the low-resolution ResNet-18 baseline by 2.25 and 2.71 percentage points, respectively. It surpasses SR-FER by 1.04 accuracy points while requiring 8.84 GFLOPs, a 54.29% reduction, with 28.01% mean mask coverage, and maintains effective recognition at unseen non-integer scales. These results show that spatial-ranking and continuous-budget driven selective restoration reduces spatial modification and computation while maintaining low-resolution FER performance, offering an efficient path to resource-constrained affective interaction.
Index Terms—Facial expression recognition, low-resolution faces, selective restoration, scale adaptation, edge computing.
I. INTRODUCTION
Facial expression recognition (FER) provides an essential perceptual cue for affective human-robot interaction by capturing fine-grained appearance changes around the brows, eyes, and mouth [1]. Robots and embedded vision devices operate under limited computation and memory, while the interaction distance can vary continuously. Increasing distance reduces the effective facial pixel scale, producing progressively stronger resolution degradation and erasing subtle expression textures. Upsampling a low-resolution face to a fixed input size changes its dimensions but cannot recover discriminative information that has already been lost. Resource constraints and dynamic interaction distances therefore form a practical deployment bottleneck for low-resolution FER.
Resource-aware FER research mainly reduces inference cost through compact architectures, efficient recognition models, and knowledge distillation [2], [3]. These methods predict expressions directly from low-resolution inputs and can reduce model size or computation, but they do not explicitly recover local cues lost during degradation. As facial resolution decreases, discriminative changes around the brows, eyes, and mouth are increasingly obscured by blur and noise, limiting the performance attainable by a lightweight classifier alone.
A second line of work addresses resolution degradation through multi-resolution representations, uncertainty modeling, filter learning, and consistency constraints [4]–[7], or introduces restoration in the image and feature domains. FSR-FER reconstructs super-resolved features from multi-scale low-resolution inputs [8], whereas SR-FER jointly learns image restoration and expression recognition with attention and prediction consistency [9]. Representative restoration-assisted methods reconstruct a complete image or feature representation, so regions with little expression-discriminative value still participate in processing. Attention and multi-scale representations can emphasize information already present in the input, but they do not directly measure the classification benefit of restoring a candidate region and therefore cannot use that benefit to select the required restoration support.
Existing approaches consequently struggle to meet three requirements together: adaptation to continuously varying degradation scales, restoration restricted to regions that benefit expression recognition, and accurate inference under edge-computing constraints. Without a mechanism that determines restoration support from both degradation severity and task demand, scale adaptation, spatial efficiency, and recognition accuracy remain separately addressed, hindering deployment in dynamic affective interaction.
To close this gap, we propose STAR-FER, a scale-and-task-adaptive selective restoration framework. Its central idea is to determine pixel restoration priority and restoration amount jointly from facial content and degradation scale, concentrating limited restoration computation on discriminative local regions. Our main contributions are as follows:
-
We introduce STAR-FER for edge-based affective interaction. It jointly models scale-conditioned region selection, lightweight selective restoration, and expression recognition, replacing fixed full-face processing with local restoration to reduce restoration computation and spatial modification while retaining complete facial context.
-
We introduce a lightweight image-scale conditioned Gate that learns a free-form spatial ranking under task
ZhongYang Wu and ZhenFeng Gan contributed equally to this work. Corresponding author: HouDe Liu.
The authors are with Tsinghua Shenzhen International Graduate School, Shenzhen 518055, China (e-mail: liu.hd@sz.tsinghua.edu.cn).
supervision and regresses a continuous restoration budget from 5% to 35%. Exact Top- projection combines them into an area-controlled, input-dependent restoration mask.
- We develop a single-model continuous-scale selective restoration mechanism whose spatial support and restoration amount vary with facial content and degradation scale. Across degradation factors from to on RAF-DB, STAR-FER achieves 80.92% mean accuracy and 71.64% Macro-F1 with 8.84 GFLOPs per forward pass.
A. Restoration-Assisted Low-Resolution Facial Expression Recognition
Super-resolution (SR) provides a foundation for recovering details in general images and faces. The field has progressed from early convolutional reconstruction to deep residual and perceptual restoration models [10]–[12], while blind SR models compound degradations beyond a fixed downsampling kernel [13], [14]. AdaFM adapts a restoration network to continuously varying restoration levels [15]. These methods improve detail reconstruction under changing degradation, but their pixel, perceptual, or adversarial objectives primarily measure image fidelity rather than the value of restored content for expression classification.
Restoration has also been incorporated into low-resolution FER. FSR-FER reconstructs super-resolved features from multi-scale low-resolution inputs [8]. SR-FER jointly learns image restoration and expression recognition, transferring task supervision through attention and prediction consistency [9]. Such methods strengthen degraded representations with reconstructed content, but representative designs still restore a complete facial image or feature representation. Their spatial processing extent is not selected according to the benefit of a region to the current expression decision. Even under joint training, fixed restoration support cannot adapt its spatial extent to the degradation scale and facial instance, so regions with little discriminative contribution still incur computation. STAR-FER instead treats spatial allocation as part of restoration-assisted FER and uses task benefit to determine where restoration modifications are needed.
B. Task-Driven Adaptive Region Selection for Restoration
Adaptive region-selection methods concentrate visual computation at input-dependent locations. Recurrent visual attention updates subsequent observation locations from previously acquired local information [16]. Spatial Transformer Networks predict position, scale, and orientation, then use differentiable resampling to align task-relevant content [17]. Spatially sparse dynamic convolutions allocate feature computation at selected
locations [18]. Input-conditioned masks and contour models further represent continuous region geometry using masks, polar distances, or deformable curves [19]–[21]. These approaches support input-dependent feature observation, alignment, sparse computation, or shape representation.
Within image restoration, ClassSR assigns different capacities to image patches according to reconstruction difficulty [22], whereas SMSR jointly learns spatial and channel masks to identify important reconstruction locations and skip redundant computation [23]. Both demonstrate that restoration computation can be allocated according to image content, but their routing decisions are derived from reconstruction difficulty or image-restoration objectives. STAR-FER learns image-conditioned spatial ranking from classification feedback on restored images and uses training-set task curves to supervise a continuous restoration budget. By combining facial content with degradation scale, the Gate directly predicts restoration locations and coverage, allocating restoration support according to the needs of expression recognition.
III. METHOD
A. Overall Framework
Fig. 1 summarizes the three motivations behind STAR-FER: selective restoration, image-conditioned region decisions, and continuous-scale adaptation. As shown in Fig. 2, the framework comprises a scale-conditioned Gate, a mask-conditioned SMSR restorer, and an FER classifier. Given a low-resolution face and a continuous degradation scale , the Gate predicts a spatial ranking field and a restoration-area ratio . Exact-budget projection then produces the mask:
The restorer receives the complete low-resolution face together with and writes restoration residuals only within the selected support. A seven-class ResNet-18 recognizes the blended image:
This unified forward path determines restoration location, restoration amount, and expression class, allowing selective restoration to vary with both the current face and its degradation level. Network dimensions, mask construction, and stage-wise training settings are summarized in Appendix A.
B. Scale-Conditioned Gate: Spatial Ranking and Continuous Budget
The scale-conditioned Gate must determine both where restoration should occur and how much of the face should be restored. It therefore constructs an image-conditioned spatial ranking from shared visual features and predicts a restoration budget from continuous scale information. Its architecture is shown in Fig. 3.

Fig. 1. Selective restoration and region decisions in STAR-FER: (a) full-face and selective restoration, (b) Gate decision features and predicted supports for two parent images at the same scale, and (c) predicted supports for one parent image under different degradation scales.
- Prefix Features and Visual-Scale Encoding: The input is bicubically resized to and processed by a frozen prefix inherited from the restoration branch:
For video input, the scale condition is computed from the native face-box short side in pixels relative to a 100-pixel reference as . The continuous scale is encoded as
and injected early into the visual branch:
Here, Stem projects the prefix feature to 48 channels, and the scale branch projects and broadcasts it over the spatial grid. A lightweight encoder built from depthwise convolutions, pointwise convolutions, GroupNorm, and SiLU produces four feature levels, denoted , and . Global average pooling of yields , while an auxiliary head produces seven logits . The decoder context is
where sg denotes stop-gradient. The auxiliary response provides semantic conditioning for the Gate, whereas the final expression prediction is produced independently by . This encoder integrates facial content and continuous degradation scale before spatial support is predicted.
- Image-Conditioned Spatial Ranking: The spatial branch encodes together with two-dimensional coordinates to produce a standardized source ranking field . A lightweight decoder fuses the multi-level features , and with the prefix feature, , and coordinates, and is modulated by the global context . It predicts a single-channel spatial correction, giving
is produced on a grid and upsampled to the input resolution. The value of determines the relative order in which pixels enter the restoration support. The source field supplies stable spatial structure, while the image-conditioned correction gives different faces distinct rankings at the same scale. This branch thus turns a shared spatial prior into input-dependent restoration locations.
- Continuous Budget and Exact Support: The restoration amount is predicted from the same context :
where the area head has a architecture and outputs a continuous area ratio between 5% and 35%. Let and . Selecting the first pixels after sorting in descending order gives
This projection converts a continuous budget into area-controlled free-form support. It allows the Gate to learn pixel

Fig. 2. Overview of STAR-FER. The lightweight continuous-scale Gate extracts visual information from a frozen SMSR prefix and jointly predicts a spatial ranking field and an image-scale conditioned restoration budget. Exact Top-k projection converts them into a free-form mask. Mask-conditioned SMSR performs sparse restoration on the selected support, and the locally blended image is passed to a ResNet-18 classifier. Network features and sparse activations are schematic. The reported 28.01% and 8.84 GFLOPs denote mean coverage across 2×2×8 and forward computation under the protocol used in this work, respectively.

Fig. 3. Scale-conditioned Gate. The frozen prefix and source spatial branch provide base features and a source ranking field. The lightweight visual-scale encoder predicts a spatial correction, the continuous budget head estimates restoration area, and exact Top-k generates the final mask.
ranking and restoration amount separately and combine them in one forward pass.
- Differentiable Spatial Learning at a Fixed Budget: The spatial ranking stage uses a fixed target area and connects the restoration task to the ranking field through a differentiable mask:
where the threshold is solved for each image by bisection. Accounting for the dependence of on , let and . The backward gradient is
During training, increases from 4 to 20 so that the ranking field learns task-related spatial order at a fixed coverage. A task-curve teacher subsequently supervises the continuous budget. This division lets task signals determine both support location and area while retaining exact-budget inference.
C. Lightweight Mask-Conditioned Selective Restoration
Selective restoration must preserve complete facial context while controlling the spatial extent of pixel modification and internal computation. We use SMSR [23] as the restoration backbone. The Gate mask is mapped to the internal grid and works with channel selection to modulate eight sparse mixing modules. The complete low-resolution face supplies restoration content throughout the network, and the mask acts as an external spatial condition during the restoration forward pass.
After the restorer produces , its output is locally blended according to (2). Pixels outside the support retain their values from , while pixels inside receive the predicted restoration residual. A ResNet-18 [24] then performs seven-class FER on the blended image. This module turns Gate support into actual restoration computation and local image modification, connecting region selection to the FER objective.
D. Stage-Wise Multi-Scale Learning
STAR-FER first establishes restoration and recognition ability, then learns image-conditioned spatial ranking, and finally fits the continuous restoration budget. Each stage uses degradation factors from to , with stage-specific update sets and supervision objectives.
- Restoration and Recognition Calibration: SMSR first learns basic restoration through multi-scale pixel supervision and channel-sparsity regularization, followed by joint adaptation with the FER classifier on mask-conditioned inputs. A high-resolution teacher then calibrates the deployed restorer and classifier with
aligns class distributions at temperature 2, aligns normalized features from the final two FER stages, and supervises restoration pixels within the selected support. This stage adapts and to locally blended images and supplies stable task gradients for spatial Gate learning.
- Spatial Gate Learning and Lightweight Distillation: At a fixed 25% budget, the spatial Gate learns pixel ranking through the classification response to the restored image. Its task supervision is
The auxiliary classifier is supervised by smoothed cross-entropy and the teacher distribution:
The lightweight Gate further distills spatial and semantic information from a heavier semantic Gate:
The Dice term compares masks for the same image and scale, the field loss compares standardized ranking fields, and semantic KD aligns auxiliary responses. The weights of the restorer, FER classifier, source spatial branch, and heavy Gate teacher are frozen, while gradients with respect to mask inputs are retained through the restorer and classifier. This stage converts restoration and recognition feedback into image-conditioned spatial rankings predicted directly by the lightweight Gate.
- Continuous Budget Learning from Task Curves: After spatial learning, the spatial Gate, restorer, and classifier are fixed and only the continuous budget head is trained. For each training image i and scale, budgets in are evaluated on the learned ranking field using
The teacher selects the minimum-score budget over the nonzero range from 0.05 to 0.35. If the discrete optimum
is internal, its neighboring scores , , and refine the target by a three-point parabola with step h = 0.05:
The area head fits with
The ranking term preserves budget order across images and scales, while the moment term matches the batch mean and standard deviation of predicted and teacher budgets. Task curves provide supervision only on the training set. At deployment, the area head regresses the budget directly from c. This final stage compresses image- and degradation-dependent restoration demand into a lightweight forward prediction, enabling continuous-scale selective restoration with one model.
IV. EXPERIMENTS
A. Datasets
RAF-DB RAF-DB is a large-scale in-the-wild facial expression dataset containing approximately 30,000 face images. Its basic and compound expression annotations were obtained through repeated crowdsourcing and reliability filtering [25]. Following the standard basic-expression protocol, we use the seven-class subset with 12,271 training and 3,068 test images. FERPlus FERPlus relabels FER2013 using independent votes from ten annotators per image, yielding a label distribution over eight expression categories [26]. The dataset contains 32,298 training and 3,589 test images.
Both datasets are evaluated at seven integer degradation scales from to , with equal weighting across scales. FERPlus recognition is evaluated on the cleaned seven-class subset containing 3,136 test images. Data processing, region parameters, and training settings are provided in Appendix A.
B. Recognition Results and Analysis
This section examines whether selective restoration improves low-resolution FER and how its effect changes with degradation severity. We compare STAR-FER with ResNet-18 applied directly to low-resolution inputs, the image-restoration method SR-FER [9], and the feature-restoration method FSR-FER [8] from to . Each scale uses all 3,068 RAF-DB test images, and the cross-scale mean equally weights the seven scales. STAR-FER uses BF16 for G and the Gate and FP32 for the FER classifier during inference.
TABLE I
MEAN RECOGNITION RESULTS ACROSS RAF-DB SCALES.
| Method | Accuracy (%) | Macro-F1 (%) |
|---|---|---|
| ResNet-18 (LR) | 78.66 | 68.94 |
| STAR-FER | 80.92 | 71.64 |
| SR-FER | 79.88 | 70.76 |
| FSR-FER | 77.01 | 68.09 |
As shown in Table I, STAR-FER achieves mean accuracy of 80.92% and Macro-F1 of 71.64%. It improves over the low-resolution baseline by 2.25 and 2.71 percentage points, SR-FER by 1.04 and 0.88 points, and FSR-FER by 3.91 and 3.56.



Fig. 4. Recognition and base support across seven RAF-DB scales. (a) Accuracy; (b) Macro-F1; (c) Mask coverage.
points, respectively. With local restoration support, STAR-FER also achieves higher mean recognition scores than full-image and full-feature restoration methods, showing that low-resolution FER can match or surpass prior methods without restoring every spatial location to the same extent.
Fig. 4(a)(b) further shows how recognition changes with degradation scale. As degradation becomes more severe, less discriminative information remains and all four methods decline; however, STAR-FER exhibits the most stable trend. From ×2 to ×8, it loses 6.47 accuracy points and 7.24 Macro-F1 points. The corresponding declines are 8.34 and 11.77 points for the low-resolution baseline, 10.40 and 13.79 points for SR-FER, and 14.53 and 17.95 points for FSR-FER. Although SR-FER leads STAR-FER by 0.90 accuracy points at ×2, STAR-FER reaches 78.06% at ×8 and exceeds SR-FER and FSR-FER by 3.03 and 8.34 points. The smaller cross-scale decline and sustained accuracy under severe degradation support the role of scale-conditioned region selection in retaining stable expression evidence as facial details disappear.
Fig. 4(c) relates recognition performance to restoration extent. STAR-FER uses 28.01% mean mask coverage, whereas SR-FER and FSR-FER process the complete image and feature space, respectively. As degradation increases from ×4 to ×8, STAR-FER expands its coverage from 27.27% to 32.85%, indicating that the Gate allocates more restoration support when visual cues become weaker while retaining compact support under milder degradation. Together with the recognition gains in Table I, this result shows that scale-dependent allocation removes most spatial modifications while preserving local information useful for FER.
To examine feature organization under severe degradation, Fig. 5 projects features from the same 3,068 RAF-DB test images at ×8 into two dimensions. Happiness forms a relatively compact cluster, and surprise also exhibits distinct grouping, whereas neutral and sadness still overlap considerably. Happiness samples in FSR-FER split into several subclusters, while SR-FER and STAR-FER exhibit more continuous within-class structures. This pattern is consistent with their stronger recognition under severe degradation and illustrates how restoration changes within-class organization. The remaining overlap
TABLE II
RECOGNITION PERFORMANCE AND GATE COVERAGE ON FERPLUS. F1 DENOTES MACRO-F1.
| STAR-FER | ResNet-18 (LR) | ||||
|---|---|---|---|---|---|
| Scale | Acc (%) | F1 (%) | Coverage (%) | Acc (%) | F1 (%) |
| ×2 | 85.71 | 75.67 | 17.23 | 85.68 | 75.72 |
| ×3 | 85.17 | 74.92 | 23.20 | 85.14 | 74.89 |
| ×4 | 84.34 | 74.45 | 28.87 | 84.02 | 74.02 |
| ×5 | 83.07 | 72.73 | 33.64 | 82.53 | 72.65 |
| ×6 | 82.68 | 72.25 | 34.77 | 80.80 | 68.62 |
| ×7 | 81.98 | 72.27 | 34.84 | 77.71 | 67.03 |
| ×8 | 79.91 | 69.81 | 34.88 | 72.54 | 58.13 |
| Mean | 83.27 | 73.16 | 29.63 | 81.20 | 70.15 |
between neutral and sadness also identifies classes that the current representations still confuse.
Table II shows that the proposed method achieves mean accuracy of 83.27% and Macro-F1 of 73.16% across the seven scales, with mean coverage of 29.63%.
C. Ablation Experiments and Mechanism Analysis
- Analysis of Scale-Encoding Benefits: To examine how scale encoding affects restoration budgets and recognition, we keep the degraded images at each scale unchanged and replace the normal Gate scale code with a constant code. Table III reports the comparison on the complete RAF-DB test set at seven degradation scales.
Table III shows that normal encoding increases mean coverage from 18.89% at ×2 to 32.85% at ×8. With the code fixed to ×2, coverage stays between 18.89% and 19.50%, reducing its seven-scale mean from 28.01% to 19.19%. Scale conditioning therefore guides restoration-budget allocation as degradation increases. Fixing the code to a mild degradation level makes the model allocate an amount close to that for ×2, even for more blurred inputs. The decrease from 28.13% to 19.53% for the same ×4 face in Fig. 6(b)(d) illustrates this budget response.
Across the seven scales, mean accuracy is 80.92% with normal scale encoding and 80.64% with fixed encoding, a

Fig. 5. t-SNE visualization of RAF-DB features at ×8.

(a) Parent face

(b) LR ×4, scale code ×4
(c) LR ×4, fixed eyes/mouth
Area 28.13%
(d) LR ×4, scale code ×2

Area 10.87%

Area 19.53%
Fig. 6. Illustration of fixed eye-and-mouth support and adaptive selection. (a) Parent face. (b) Adaptive mask for a ×4 input with its corresponding scale condition. (c) Fixed eye-and-mouth mask on the same ×4 input. (d) Adaptive mask with the input kept at ×4 and the scale code fixed to ×2.
TABLE III
NORMAL VERSUS CONSTANT ×2 SCALE ENCODING. THE ACTUAL INPUT DEGRADATION IS UNCHANGED.
| Input scale | Accuracy (%) | Coverage (%) | ||
|---|---|---|---|---|
| Normal | Fixed ×2 | Normal | Fixed ×2 | |
| ×2 | 84.53 | 84.53 | 18.89 | 18.89 |
| ×3 | 83.04 | 83.94 | 23.76 | 18.93 |
| ×4 | 81.13 | 80.87 | 27.27 | 19.09 |
| ×5 | 80.70 | 80.61 | 29.70 | 19.33 |
| ×6 | 80.08 | 79.53 | 31.14 | 19.34 |
| ×7 | 78.88 | 78.23 | 32.48 | 19.50 |
| ×8 | 78.06 | 76.76 | 32.85 | 19.28 |
| Mean | 80.92 | 80.64 | 28.01 | 19.19 |
difference of 0.28 percentage points. Normal encoding yields accuracy higher by 0.55, 0.65, and 1.30 percentage points at ×6, ×7, and ×8, respectively. Meanwhile, mean mask coverage differs by 8.82 percentage points, with larger differences in restoration extent under severe degradation. These results indicate that fixed encoding restricts the Gate's ability to adjust restoration extent to degradation severity. Under mild degradation, the input retains substantial discriminative information, so restricting restoration extent has a relatively small effect on recognition. As degradation intensifies, fine-grained expression cues disappear, and limited restoration support becomes less effective at compensating for the loss of discriminative information, leading to a larger performance decline. Scale conditioning instead allocates the restoration budget according to input degradation, providing more extensive local support under severe low-resolution conditions and mitigating its effect on recognition.
We further fix spatial ranking while retaining each image's own predicted budget to examine the source of location differences. Replacing image-conditioned ranking with a fixed learned template increases mean cross-parent mask IoU from 0.5705 to 0.9586. Higher IoU indicates more similar supports across faces. The near-unit IoU after replacement therefore shows that restoration locations become largely shared, with the remaining differences mainly arising from boundary-size changes induced by per-image budgets. The image-conditioned spatial branch is the main source of personalized locations through its adaptive pixel ranking, while scale encoding primarily regulates restoration amount.
- Adaptive Gate versus Fixed Eye-and-Mouth Regions: We compare fixed anatomical support with adaptive selection using the same restorer and FER classifier.
The fixed support consists of three ellipses covering the eyes and mouth. Evaluation uses all 3,068 RAF-DB test images at seven scales. Table IV reports scale-wise recognition results, and Fig. 6(b)(c) illustrates the two supports.
As shown in Table IV, STAR-FER achieves mean accuracy of 80.92%, compared with 80.43% for fixed eye-and-mouth support, a gain of 0.48 percentage points in this comparison. STAR-FER is lower by 0.10 and 0.80 points at ×2 and ×3, respectively. It outperforms fixed support from ×4 onward,
TABLE IV
RAF-DB ACCURACY OF THE ADAPTIVE GATE AND FIXED EYE-AND-MOUTH SUPPORT ACROSS SEVEN SCALES. ACC DENOTES STAR-FER MINUS FIXED ACCURACY.
| Scale | STAR-FER Acc (%) | Fixed Acc (%) | Acc (pp) |
|---|---|---|---|
| ×2 | 84.53 | 84.63 | -0.10 |
| ×3 | 83.04 | 83.84 | -0.80 |
| ×4 | 81.13 | 81.02 | +0.11 |
| ×5 | 80.70 | 80.44 | +0.26 |
| ×6 | 80.08 | 79.37 | +0.71 |
| ×7 | 78.88 | 77.77 | +1.11 |
| ×8 | 78.06 | 75.97 | +2.09 |
| Mean | 80.92 | 80.43 | +0.48 |
with gains of 0.71, 1.11, and 2.09 points at ×6, ×7, and ×8. Accuracy declines by 8.66 points from ×2 to ×8 with fixed support, compared with 6.47 points for STAR-FER. Adaptive selection therefore retains recognition performance more effectively under severe degradation.
This pattern indicates that, under mild degradation, the eyes and mouth retain substantial expression cues, and restoring these key locations satisfies most recognition needs. Fixed eye-and-mouth support can therefore match or slightly outperform adaptive selection. As resolution decreases further, local textures and fine-grained expression information disappear, making fixed eye-and-mouth restoration less effective at compensating for the lost discriminative information. STAR-FER instead adjusts restoration locations and coverage according to facial content and degradation severity, allocating support to regions more useful for expression recognition. The adaptive spatial support in Fig. 6(b)(c), together with the increasing recognition advantage under severe degradation in Table IV, shows that adaptive region selection mitigates the limitations of fixed eye-and-mouth restoration and better preserves recognition performance at very low resolutions.
- Dense versus Sparse Restoration Computation: To examine whether selected support translates into computational savings, we fix network weights and masks and compare the dense masked and true SMSR sparse paths of the same model. Table V reports computation including the Gate, restorer, and FER classifier.
TABLE V
EXECUTION-PATH COMPARISON UNDER IDENTICAL WEIGHTS AND MASKS. COMPUTATION IS AVERAGED OVER SEVEN SCALES FOR THE COMPLETE PIPELINE.
| Execution path | Cost (GFLOPs) | Reduction (%) |
|---|---|---|
| Dense masked | 9.5646 | — |
| True SMSR sparse | 8.8380 | 7.60 |
Table V shows that true sparse execution reduces mean computation from 9.5646 to 8.8380 GFLOPs, saving 0.7266 GFLOPs, or 7.60%. With identical restoration support, the dense masked path still performs convolutions over the complete spatial grid, whereas the sparse path skips part of the computation according to spatial support and channel selection. Reducing restoration area and reducing convolutional operations thus serve distinct roles: the Gate determines local restoration extent, and sparse SMSR execution translates this spatial selection into computational savings. This result supports combining spatial selection with sparse execution in a lightweight restoration backbone to reduce forward computation.
D. Computational Efficiency
TABLE VI
MODEL PARAMETERS, MEAN RESTORATION COVERAGE, AND COMPUTATIONAL COST.
| Method | Parameters (M) | Coverage (%) | Cost (GFLOPs) |
|---|---|---|---|
| STAR-FER | 12.885 | 28.01 | 8.84 |
| SR-FER | 14.21 | 100.00 | 19.34 |
| FSR-FER | 35.42 | 100.00 | 19.41 |
Table VI compares model size, mean restoration coverage, and computational cost. STAR-FER contains 12.885 M parameters and performs selective restoration over 28.01% mean spatial support, requiring 8.84 GFLOPs for one forward pass through the Gate, restorer, and FER classifier. SR-FER and FSR-FER process the complete image or feature space and require 19.34 and 19.407 GFLOPs, respectively. STAR-FER therefore reduces computation by 54.29% and 54.45%. Together with the preceding recognition results, these measurements show that STAR-FER substantially reduces restoration extent and computational cost while maintaining recognition performance, making it better suited to affective interaction on edge devices.
E. Continuous-Scale Adaptation Analysis
Multi-scale training uses only the seven integer factors from ×2 to ×8. To test direct extrapolation of the continuous scale condition, Table VII evaluates the frozen model at three unseen non-integer scales. Fig. 7 further visualizes continuous responses between the integer training scales for the same parent image.
Table VII shows that, as the effective factor increases from ×4.55 to ×7.14, mean Gate coverage rises from 28.60% to 32.52% while accuracy decreases smoothly from 80.35% to 78.10%. These unseen-scale results indicate that continuous scale conditioning adjusts the restoration budget between adjacent factors rather than merely memorizing the seven training scales.
Fig. 7 shows the regions directly predicted by the current Gate for the same parent image at 12 scales from ×2 to ×8. Union-mask coverage increases from 21.68% to 33.40%, while the number, location, and contour of connected regions vary with scale. This example shows that continuous scale conditioning changes both the restoration budget and the spatial distribution of the free-form support.
F. Scale Budget and Instance Variation Analysis
Beyond mean recognition scores, we measure region-area variation and cross-image mask IoU for the same frozen Gate

Fig. 7. Restoration masks predicted by the current continuous-scale Gate for the same parent image across degradation scales. Orange, green, and blue denote the three largest connected components in descending area; values below each image give union-mask coverage.
TABLE VII
RAF-DB RECOGNITION AND GATE COVERAGE AT UNSEEN NON-INTEGER SCALES.
| Scale | Acc (%) | F1 (%) | Coverage (%) |
|---|---|---|---|
| 80.35 | 71.50 | 28.60 | |
| 79.47 | 70.27 | 31.57 | |
| 78.10 | 69.31 | 32.52 |
TABLE VIII
SCALE-WISE RAF-DB GATE-REGION STATISTICS.
| Scale | Coverage (%) | Std. (%) | Cross-IoU |
|---|---|---|---|
| 18.89 | 1.56 | 0.391 | |
| 23.76 | 1.48 | 0.484 | |
| 27.27 | 1.22 | 0.554 | |
| 29.70 | 0.99 | 0.604 | |
| 31.14 | 0.78 | 0.632 | |
| 32.48 | 0.56 | 0.658 | |
| 32.85 | 0.48 | 0.669 | |
| Mean | 28.01 | 1.01 | 0.570 |
on 3,068 RAF-DB test images to examine whether it produces personalized regions or a single fixed template.
Table VIII shows mean Gate coverage of 28.01%, increasing with degradation severity. Cross-image IoU ranges from 0.391 to 0.669, indicating that the predicted regions vary across images rather than collapsing to a single fixed template. Its increase at stronger degradation indicates that different images share more restoration support when visual evidence is weak. These results further show that the method learns personalized restoration regions for different facial appearances, adapting its support to expression recognition across faces.
G. Real-World Deployment and Evaluation
- PC-Based Video Evaluation: To examine restoration responses and recognition outputs under continuous input, we evaluate a recorded video on a PC equipped with an Intel Core i5-12500H processor and an NVIDIA GeForce RTX 3050 Ti Laptop GPU. The three methods use the same video, face detection, and cropping conditions. We compare adjacent-frame prediction switching rates and mean method latency.
Fig. 8(a)(b) shows the input and locally fused result at 22.97 s, with a native face short side of 30 pixels, a scale condition of 3.33, and mask coverage of 24.02%. The difference map shows that restoration changes are confined to the predicted support, consistent with the local fusion in (2). Fig. 8(c)(d) shows the continuous response from 5 to 33 s of the original video. The effective degradation scale rises from 2 to approximately 3.7 and then returns to 2, while mask coverage generally increases and then decreases, fluctuating between approximately 15% and 26%. The plateaus at 2 in the early and late intervals result from the lower bound on the scale condition. As effective degradation increases, the Gate generally expands restoration support; as the facial pixel scale recovers, the support contracts. This response shows that the scale-conditioned Gate adapts restoration budgets and spatial support to changes in the effective facial pixel scale.
Fig. 9(a) shows a prediction switching rate of 10.08% for STAR-FER, compared with 11.17% for SR-FER and 19.72% for FSR-FER, reductions of 1.09 and 9.64 percentage points, respectively. Under the same video, detection, and cropping conditions, STAR-FER switches classes less frequently, producing more consistent predictions, particularly relative to FSR-FER. These observations indicate that selective restoration maintains comparatively stable expression predictions as the facial pixel scale changes continuously.
Fig. 9(b) reports method latency. STAR-FER requires 46.08
(a) Input + mask

s = 3.33
Mask 24.02%
(b) Restoration and residual

Pred.: Happy 22.97 s

Mean IX - L1
(c) Effective degradation scale s

(d) Mask coverage
Fig. 8. Selective restoration and scale response in the PC deployment experiment. (a) Input with the predicted mask. (b) Locally fused result X and channel-mean to its right. (c) Effective degradation scale s. (d) Mask coverage. Curves show valid observations from 5 to 33 s; dots mark 22.97 s, with s = 3.33 and 24.02% coverage.
ms on average, reducing latency by 3.97 ms (7.93%) relative to FSR-FER at 50.05 ms and by 39.66 ms (46.26%) relative to SR-FER at 85.74 ms. Together with the switching-rate results, this PC-based video evaluation shows that STAR-FER achieves both fewer class switches and lower method latency, supporting the practical value of selective restoration under continuous visual input.
(a) Prediction switching

(b) Inference latency
Fig. 9. Overall PC deployment statistics. (a) Prediction switching rates over 913 adjacent valid-frame pairs. (b) Mean method latency over 914 detected faces.
- Edge Deployment and Evaluation: To examine inference efficiency on a resource-constrained device, we conduct edge deployment tests on an NVIDIA Jetson Orin Nano Super Developer Kit. The robot uses a DECXIN USB Camera with 1080p imaging and a distortion-free field of view. The software environment comprises Ubuntu 22.04.5 LTS, Jetson Linux 36.4.3, and CUDA 12.6.
We compare ResNet-18 (LR), SR-FER, FSR-FER, and the dense masked and sparse execution paths of STAR-FER.
Single-frame inference uses a batch size of 1. Table IX reports mean latency, P95 latency, and peak CUDA tensor allocation measured by PyTorch.
TABLE IX
SINGLE-FRAME INFERENCE ON JETSON ORIN NANO SUPER WITH BATCH SIZE 1. MEMORY DENOTES PEAK CUDA TENSOR ALLOCATION MEASURED BY PYTORCH.
| Method | Mean (ms) | P95 (ms) | Peak CUDA memory (MB) |
|---|---|---|---|
| ResNet-18 (LR) | 15.37 | 23.58 | 92.40 |
| SR-FER | 132.06 | 141.51 | 727.54 |
| FSR-FER | 146.21 | 149.54 | 202.75 |
| STAR-FER (Dense) | 85.46 | 88.93 | 115.29 |
| STAR-FER (Sparse) | 122.87 | 127.53 | 115.26 |
As shown in Table IX, ResNet-18 applied directly to low-resolution inputs has the lowest mean latency at 15.37 ms. Among restoration-assisted methods, the dense masked path of STAR-FER takes 85.46 ms on average, reducing latency by 35.29% relative to SR-FER and 41.55% relative to FSR-FER. The sparse path takes 122.87 ms, with corresponding reductions of 6.96% and 15.96%. Their P95 latencies of 88.93 and 127.53 ms are also below the 141.51 ms of SR-FER and 149.54 ms of FSR-FER. These findings are consistent with the preceding analysis of computational savings from the compact restoration architecture and selective restoration path, showing that the design delivers practical latency reductions over full-face restoration baselines on Jetson. The reductions in both mean and P95 latency extend this advantage from average processing efficiency to frames requiring longer inference times, helping reduce response delays during on-device interaction. Together with the recognition results, these measurements support the feasibility of deploying STAR-FER on resource-constrained affective interaction devices: it recovers local expression cues and maintains recognition performance while reducing the inference burden on the target hardware.
Table IX also shows similar peak CUDA tensor allocations for the dense masked and sparse paths, at 115.29 and 115.26 MB, respectively. The sparse path reduces this peak by 84.16% relative to SR-FER at 727.54 MB and by 43.15% relative to FSR-FER at 202.75 MB. Together with the latency measurements, these results show that STAR-FER reduces inference time and CUDA tensor memory demand on the evaluated edge platform, while switching to sparse execution has little effect on peak allocation.
Despite its lower theoretical operation count, the sparse path has 37.41 ms higher mean latency than the dense masked path. Module-level measurements show similar times for the Gate, Top-k mask generation, and FER classifier. In contrast, the SMSR restorer and mask blending increase from 43.59 to 80.31 ms, an additional 36.72 ms that accounts for most of the total latency gap. PyTorch operator records further identify mask indexing, convolution-window unfolding, matrix multiplication, and result write-back in the current sparse implementation. Scheduling and data-access overhead from these operations may offset part of the convolutional savings, limiting the hardware speedup obtained from the lower operation count. The dense masked path consequently provides better inference efficiency in the current implementation. The sparse path still requires optimization of data organization and operator execution, which remains a limitation of the method.
V. CONCLUSION
We presented STAR-FER, a computationally lightweight FER framework for on-device deployment. Its scale-conditioned Gate jointly predicts an image-dependent spatial ranking and a continuous restoration budget, which exact-support projection converts into a free-form mask. The mask-conditioned restorer performs local sparse restoration with complete facial context, followed by FER classification. Across seven degradation scales on the complete RAF-DB test set, STAR-FER achieves 80.92% mean accuracy, 71.64% Macro-F1, and 28.01% mean coverage with 8.84 GFLOPs per forward pass. Continuous-scale and instance-level region statistics further show that one model can adjust restoration amount with degradation severity and produce different spatial supports for different inputs.
Limitations and Future Work: The current Gate produces instance-varying restoration regions, but their spatial differences have not yet translated into consistent recognition gains over a strong fixed spatial prior. Jetson measurements further show that the current sparse SMSR path is slower than dense masked execution, so its theoretical savings have not fully translated into hardware speedup. Future work will further strengthen the connection between spatial ranking and classification benefit.
APPENDIX A
IMPLEMENTATION DETAILS AND DATA PROTOCOL
A. Gate Dimensions and Spatial-Field Processing
After resizing the input to , the frozen prefix produces a feature map. The four levels of the lightweight encoder have dimensions , , , and . The global feature, seven-dimensional auxiliary class distribution, and two-dimensional scale code form the 137-dimensional context. The spatial decoder projects each of the first three feature levels and the prefix feature to 24 channels and concatenates them with the single-channel source field and two coordinate channels. A context projection modulates the decoder. The area head has a architecture with 4,449 trainable parameters.
Spatial fields are standardized independently for each image. For a field with spatial mean and standard deviation ,
This definition is used for the source field and for fields compared during distillation. The final ranking field follows (7); the source prefix remains a fixed Gate feature extractor and is included in forward computation.
B. Mask Construction and Differentiable Backward Pass
At inference, the area head produces . The selected pixel count is and is clamped to
TABLE X STAGE-WISE TRAINING OF STAR-FER.
| Stage | Updated components | Main supervision |
|---|---|---|
| G/F calibration I | Continuous restorer parameters | Eq. (12) |
| G/F calibration II | Restorer and FER layer3/4/FC | Eq. (12) |
| Spatial Gate learning | Lightweight visual, spatial, and auxiliary branches | Eqs. (13)–(15) |
| Continuous budget learning | 4,449-parameter area head | Eq. (18) |
the valid pixel range. The implementation sorts the flattened in descending order and selects indices with zero-based rank below . Equal scores are truncated according to the index order returned by the sorting implementation, so the output always contains exactly pixels.
Spatial Gate training uses the fixed-budget mask in (10). For each image, the threshold search interval extends the current field minimum and maximum by , and bisection solves for a mask mean of . During the first 80% of updates, increases smoothly from 4 to 20 and then remains at 20. Backpropagation uses the implicit gradient in (11).
C. Stage-Wise Optimization Settings
Table X lists the principal training dependencies and update sets for the current RAF-DB model. The high-resolution teacher, heavy semantic Gate, and source spatial branch provide supervision or initialization and do not enter the deployed classification path.
The two G/F calibration phases each run for seven epochs. Spatial Gate learning uses a fixed 25% budget; the current lightweight initialization is selected at epoch 2, and the heavy semantic Gate teacher is selected at epoch 24. The continuous budget head is trained for 24 epochs with AdamW, an initial learning rate of , weight decay , and gradient-norm clipping at 5. The first epoch uses linear warm-up, followed by cosine decay to 0.1 of the initial learning rate.
For budget ranking, samples in a shuffled mini-batch are paired with cyclically shifted samples. Only pairs whose teacher budgets differ by at least 0.05 are retained, and a Softplus ranking objective with temperature 0.03 is applied. The moment term matches the batch means and standard deviations of predicted and teacher budgets. The teacher evaluates , while both the continuous targets and final predictions are restricted to 0.05–0.35.
D. Data Degradation and Splits
- Resolution Degradation: RAF-DB uses the official aligned RGB faces as references. For each degradation factor , Pillow bicubic interpolation downsamples the reference to , where , and then resizes it back to for caching. The model loader converts each image to a RGB input.
FERPlus uses its original images as references. The same bicubic procedure downsamples each image to and restores it to . The seven native low-resolution side lengths are 24, 16, 12, 10, 8, 7, and 6 pixels, respectively, followed by conversion to a RGB input.
-
FERPlus Label Processing: FERPlus provides votes from ten annotators per image. Each image is assigned the category with the most votes. Samples labeled Contempt are removed, leaving seven expression classes.
-
Training and Test Splits: RAF-DB follows the official basic-expression split, with 12,271 training and 3,068 test parent images. FERPlus retains its original training and test splits. All cleaned training samples are used for training, and all cleaned test samples are used for evaluation.
REFERENCES
[1] Z. Liu et al., “A facial expression emotion recognition based human-robot interaction system,” IEEE/CAA J. Autom. Sinica, vol. 4, no. 4, pp. 668–676, 2017.
[2] M. Aly, A. Ghallab, and I. S. Fathi, “Enhancing facial expression recognition system in online learning context using efficient deep learning model,” IEEE Access, vol. 11, pp. 121419–121433, 2023.
[3] T. Ma, W. Tian, and Y. Xie, “Multi-level knowledge distillation for low-resolution object detection and facial expression recognition,” Knowl.-Based Syst., vol. 240, 2022, Art. no. 108136.
[4] F. V. Massoli, D. Cafarelli, C. Gennaro, G. Amato, and F. Falchi, "MAFER: A multi-resolution approach to facial expression recognition," arXiv preprint arXiv:2105.02481, 2021.
[5] L. Lo, B.-K. Ruan, H.-H. Shuai, and W.-H. Cheng, “Modeling uncertainty for low-resolution facial expression recognition,” IEEE Trans. Affect. Comput., vol. 15, no. 1, pp. 198–209, 2024.
[6] Y. Yan, Z. Zhang, S. Chen, and H. Wang, “Low-resolution facial expression recognition: A filter learning perspective,” Signal Process., vol. 169, 2020, Art. no. 107370.
[7] B. Lee, K. Ko, J. Hong, and H. Ko, “Hard sample-aware consistency for low-resolution facial expression recognition,” in Proc. IEEE/CVF Winter Conf. Appl. Comput. Vis., 2024, pp. 198–207.
[8] F. Nan et al., “Feature super-resolution based facial expression recognition for multi-scale low-resolution images,” Knowl.-Based Syst., vol. 236, 2022, Art. no. 107678.
[9] Y. Xie, W. Tian, L. Song, R. Xue, Z. Zha, and B. Wen, “A joint learning method with consistency-aware for low-resolution facial expression recognition,” Expert Syst. Appl., vol. 244, 2024, Art. no. 123022.
[10] C. Dong, C. C. Loy, K. He, and X. Tang, “Learning a deep convolutional network for image super-resolution,” in Computer Vision – ECCV 2014. Springer International Publishing, 2014, pp. 184–199.
[11] B. Lim, S. Son, H. Kim, S. Nah, and K. M. Lee, “Enhanced deep residual networks for single image super-resolution,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit. Workshops, 2017, pp. 1132–1140.
[12] X. Wang et al., “ESRGAN: Enhanced super-resolution generative adversarial networks,” in Computer Vision – ECCV 2018 Workshops, ser. Lecture Notes in Computer Science, vol. 11133. Springer International Publishing, 2019, pp. 63–79.
[13] K. Zhang, J. Liang, L. Van Gool, and R. Timofte, “Designing a practical degradation model for deep blind image super-resolution,” in Proc. IEEE/CVF Int. Conf. Comput. Vis., 2021, pp. 4771–4780.
[14] X. Wang, L. Xie, C. Dong, and Y. Shan, “Real-ESRGAN: Training real-world blind super-resolution with pure synthetic data,” in Proc. IEEE/CVF Int. Conf. Comput. Vis. Workshops, 2021, pp. 1905–1914.
[15] J. He, C. Dong, and Y. Qiao, “Modulating image restoration with continual levels via adaptive feature modification layers,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., 2019, pp. 11048–11056.
[16] V. Mnih, N. Heess, A. Graves, and K. Kavukcuoglu, “Recurrent models of visual attention,” in Adv. Neural Inf. Process. Syst., vol. 27, 2014, pp. 2204–2212.
[17] M. Jaderberg, K. Simonyan, A. Zisserman, and K. Kavukcuoglu, “Spatial transformer networks,” in Adv. Neural Inf. Process. Syst., vol. 28, 2015, pp. 2017–2025.
[18] T. Verelst and T. Tuytelears, “Dynamic convolutions: Exploiting spatial sparsity for faster inference,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., 2020, pp. 2320–2329.
[19] Z. Tian, C. Shen, and H. Chen, “Conditional convolutions for instance segmentation,” in Proc. Eur. Conf. Comput. Vis., 2020, pp. 282–298.
[20] E. Xie et al., “PolarMask: Single shot instance segmentation with polar representation,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., 2020, pp. 12193–12202.
[21] S. Peng, W. Jiang, H. Pi, X. Li, H. Bao, and X. Zhou, “Deep snake for real-time instance segmentation,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., 2020, pp. 8530–8539.
[22] X. Kong, H. Zhao, Y. Qiao, and C. Dong, “ClassSR: A general framework to accelerate super-resolution networks by data characteristic,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., 2021, pp. 12011–12020.
[23] L. Wang et al., “Exploring sparsity in image super-resolution for efficient inference,” in Proc. IEEE/CVF Conf. Comput. Vis. Pattern Recognit., Jun. 2021, pp. 4915–4924. [Online]. Available: https://openaccess.thecvf.com/content/CVPR2021/html/Wang_Exploring_Sparsity_in_Image_Super_Resolution_for_Efficient_Inference_CVPR_2021_paper.html
[24] K. He, X. Zhang, S. Ren, and J. Sun, “Deep residual learning for image recognition,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2016, pp. 770–778. [Online]. Available: https://openaccess.thecvf.com/content/cvpr_2016/html/He_Deep_Residual_Learning_CVPR_2016_paper.html
[25] S. Li, W. Deng, and J. Du, “Reliable crowdsourcing and deep locality-preserving learning for expression recognition in the wild,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2017, pp. 2584–2593.
[26] E. Barsoum, C. Zhang, C. Canton Ferrer, and Z. Zhang, “Training deep networks for facial expression recognition with crowd-sourced label distribution,” in Proc. 18th ACM Int. Conf. Multimodal Interact., 2016, pp. 279–283. [Online]. Available: https://doi.org/10.1145/2993148.2993165