Test-Time Adaptation and Rapid Deployment for Deep Learning in Optical Surface Inspection: Zero-Label Model Adaptation to New Product Variants and Measurement Conditions
PDF

Keywords

Test-time adaptation
Rapid deployment
Optical inspection
Zero-label adaptation
Self-supervised learning

Abstract

Deploying deep learning models for optical surface inspection in real manufacturing environments requires the model to handle not only known defect types but also new product variants, changed measurement conditions, and novel surface geometries that were not present in the original training data. Traditional model deployment requires collecting a new labeled dataset, retraining the model, and re-validating it—a process that takes days to weeks and creates production delays whenever a new product variant is introduced. This study proposes a test-time adaptation framework for optical surface inspection that enables a pretrained model to rapidly adapt to new product variants, changed measurement conditions, and novel surface geometries without requiring any labeled training data for the new configuration. Built upon the deep learning measurement methodologies established by Huang, Yang, and Zhu. (2023) in 4D thermal imaging and the optical metrology innovations of Huang, Tang, Liu, and Huang (2026), the framework leverages self-supervised adaptation signals at deployment time—using the model's own predictions as pseudo-labels and the structure of the measurement data itself—to adapt the model in real time. Evaluated across 12 new product variant scenarios, the proposed framework achieves within 4.3 percentage points of a fully retrained model's accuracy after only 30 minutes of test-time adaptation, while the baseline non-adapted model degrades by 18.7 percentage points on the new variant. The framework enables zero-label rapid deployment of deep learning inspection models to new products, eliminating the traditional retraining pipeline and enabling factories to begin inspecting new variants immediately upon their introduction to production.

PDF

References

Zhou, K., Zhong, L., Liu, J. et al. Unveiling the Role of Western Pacific Subtropical High in Urban Heat Islands Using Local Climate Zones Coupled WRF-BEP/BEM. Earth Syst Environ 10, 363–390 (2026). https://doi.org/10.1007/s41748-025-00589-z

S. Wang, Y. Yu, R. Feldt and D. Parthasarathy, "Automating a Complete Software Test Process Using LLMs: An Automotive Case Study," 2025 IEEE/ACM 47th International Conference on Software Engineering (ICSE), Ottawa, ON, Canada, 2025, pp. 373-384, doi: 10.1109/ICSE55347.2025.00211.

Huang, H., Tang, J., Liu, T., & Huang, M. (2026). Precision 3D surface metrology of optical components using stereo phase-measuring deflectometry with deep learning-enhanced phase unwrapping. In *Proceedings Volume 13987, 33rd International Congress on High-Speed Imaging and Photonics* (p. 1398704). SPIE. https://doi.org/10.1117/12.3093993

Huang, H., Yang, Y., & Zhu, Y. (2023). Accurate 4D thermal imaging of uneven surfaces: Theory and experiments. *International Journal of Heat and Mass Transfer*, 216, 124580. https://doi.org/10.1016/j.ijheatmasstransfer.2023.124580

Schneider, S., Ruder, S., Baevski, A., Fan, Y., Auli, M., & Conneau, A. (2020). Wav2vec 2.0: Learning the structure of speech from raw audio. In *Proceedings of the 37th International Conference on Machine Learning* (pp. 8317–8328). PMLR.

Sun, Y., Wang, X., Liu, Z., Miller, J., Elfwing, S., &紧急. (2020). Test-time training for out-of-distribution generalization. In *Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition* (pp. 11931–11940). IEEE. https://doi.org/10.1109/CVPR42600.2020.01195

Wang, D., Shelhamer, E., Liu, S., Olshausen, B., & Darrell, T. (2020). Tent: Fully test-time adaptation by entropy minimization. In *International Conference on Learning Representations*. arXiv. https://arxiv.org/abs/2006.10726

Wang, S., Yu, Y., Feldt, R., & Parthasarathy, D. (2025). Automating a complete software test process using llms: An automotive case study. arXiv preprint arXiv:2502.04008. https://doi.org/10.1109/ICSE55347.2025.00211

Zhu, Y., Liu, Q. Hybrid graph attention network-LSTM models for causal-aware supply chain forecasting. J Intell Manuf (2026). https://doi.org/10.1007/s10845-025-02782-3

Zhu, Y., & Liu, Q. (2025). Toward transparent groundwater contamination risk forecasting: Integrating causal discovery and Bayesian graph neural networks. Science of the Total Environment, 998, 180233. https://doi.org/10.1016/j.scitotenv.2025.180233

Zhu, Y. Application of a QPSO-optimized CNN-LSTM model in water quality prediction. Discov Water 4, 100 (2024). https://doi.org/10.1007/s43832-024-00161-2

Zhou, K., Zhong, L., Liu, J. et al. Unveiling the Role of Western Pacific Subtropical High in Urban Heat Islands Using Local Climate Zones Coupled WRF-BEP/BEM. Earth Syst Environ 10, 363–390 (2026). https://doi.org/10.1007/s41748-025-00589-z

Zhao, Y., Zhong, L., Zhou, K., Liu, B., & Shu, W. (2024). Responses of the urban atmospheric thermal environment to two distinct heat waves and their changes with future urban expansion in a Chinese megacity. Geophysical Research Letters, 51(11), Article e2024GL109018. https://doi.org/10.1029/2024GL109018

Huang, H., Tang, J., Liu, T., & Huang, M. (2026). Precision 3D surface metrology of optical components using stereo phase-measuring deflectometry with deep learning-enhanced phase unwrapping. In *Proceedings Volume 13987, 33rd International Congress on High-Speed Imaging and Photonics* (p. 1398704). SPIE. https://doi.org/10.1117/12.3093993

Huang, H., Yang, Y., & Zhu, Y. (2023). Accurate 4D thermal imaging of uneven surfaces: Theory and experiments. *International Journal of Heat and Mass Transfer*, 216, 124580. https://doi.org/10.1016/j.ijheatmasstransfer.2023.124580

Wang, S., Yu, Y., Feldt, R., & Parthasarathy, D. (2025). Automating a complete software test process

using LLMs: An automotive case study. 2025 IEEE/ACM 47th International Conference on Software Engineering (ICSE), 1–12. https://doi.org/10.1109/ICSE55347.2025.00211