Skip to main content

Adaptive Transformers for Robust Few-shot Cross-domain Face Anti-spoofing

  • Conference paper
  • First Online:
Computer Vision – ECCV 2022 (ECCV 2022)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 13673))

Included in the following conference series:

Abstract

While recent face anti-spoofing methods perform well under the intra-domain setups, an effective approach needs to account for much larger appearance variations of images acquired in complex scenes with different sensors for robust performance. In this paper, we present adaptive vision transformers (ViT) for robust cross-domain face anti-spoofing. Specifically, we adopt ViT as a backbone to exploit its strength to account for long-range dependencies among pixels. We further introduce the ensemble adapters module and feature-wise transformation layers in the ViT to adapt to different domains for robust performance with a few samples. Experiments on several benchmark datasets show that the proposed models achieve both robust and competitive performance against the state-of-the-art methods for cross-domain face anti-spoofing using a few samples.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Subscribe and save

Springer+ Basic
EUR 32.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 89.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 119.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Similar content being viewed by others

References

  1. Agarwal, A., Singh, R., Vatsa, M.: Face anti-spoofing using haralick features. In: International Conference on Biometrics Theory, Applications and Systems (BTAS) (2016)

    Google Scholar 

  2. Antoniou, A., Storkey, A., Edwards, H.: Data augmentation generative adversarial networks. In: International Conference on Learning Representations (ICLR) (2018)

    Google Scholar 

  3. Atoum, Y., Liu, Y., Jourabloo, A., Liu, X.: Face anti-spoofing using patch and depth-based CNNs. In: International Joint Conference on Biometrics (IJCB) (2017)

    Google Scholar 

  4. Boulkenafet, Z., Komulainen, J., Hadid, A.: Face anti-spoofing based on color texture analysis. In: International Conference on Image Processing (ICIP) (2015)

    Google Scholar 

  5. Boulkenafet, Z., Komulainen, J., Li, L., Feng, X., Hadid, A.: OULU-NPU: a mobile face presentation attack database with real-world variations. In: International Conference on Automatic Face & Gesture Recognition (FG) (2017)

    Google Scholar 

  6. Chefer, H., Gur, S., Wolf, L.: Transformer interpretability beyond attention visualization. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2021)

    Google Scholar 

  7. Chen, Z., et al.: Generalizable representation learning for mixture domain face anti-spoofing. In: Association for the Advancement of Artificial Intelligence (AAAI) (2021)

    Google Scholar 

  8. Chetty, G.: Biometric liveness checking using multimodal fuzzy fusion. In: IEEE International Conference on Fuzzy Systems (FUZZ-IEEE) (2010)

    Google Scholar 

  9. Chingovska, I., Anjos, A., Marcel, S.: On the effectiveness of local binary patterns in face anti-spoofing. In: Proceedings of the International Conference of Biometrics Special Interest Group (BIOSIG) (2012)

    Google Scholar 

  10. Deng, J., Dong, W., Socher, R., Li, L.J., Li, K., Fei-Fei, L.: Imagenet: a large-scale hierarchical image database. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2009)

    Google Scholar 

  11. Dosovitskiy, A., et al.: An image is worth 16\(\times \)16 words: transformers for image recognition at scale. In: International Conference on Learning Representations (ICLR) (2021)

    Google Scholar 

  12. Feng, L., et al.: Integration of image quality and motion cues for face anti-spoofing: a neural network approach. J. Vis. Commun. Image Represent. 38, 451–460 (2016)

    Article  Google Scholar 

  13. Finn, C., Abbeel, P., Levine, S.: Model-agnostic meta-learning for fast adaptation of deep networks. In: International Conference on Machine Learning (ICML) (2017)

    Google Scholar 

  14. de Freitas Pereira, T., Anjos, A., De Martino, J.M., Marcel, S.: LBP-TOP based countermeasure against face spoofing attacks. In: Asian Conference on Computer Vision (ACCV) (2012)

    Google Scholar 

  15. George, A., Marcel, S.: On the effectiveness of vision transformers for zero-shot face anti-spoofing. In: International Joint Conference on Biometrics (IJCB) (2021)

    Google Scholar 

  16. George, A., Mostaani, Z., Geissenbuhler, D., Nikisins, O., Anjos, A., Marcel, S.: Biometric face presentation attack detection with multi-channel convolutional neural network. IEEE Trans. Inf. Forensics Secur. 15, 42–55 (2020)

    Article  Google Scholar 

  17. Guo, Y., et al.: A broader study of cross-domain few-shot learning. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12372, pp. 124–141. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58583-9_8

    Chapter  Google Scholar 

  18. Hariharan, B., Girshick, R.: Low-shot visual recognition by shrinking and hallucinating features. In: IEEE International Conference on Computer Vision (ICCV) (2017)

    Google Scholar 

  19. Houlsby, N., et al.: Parameter-efficient transfer learning for NLP. In: International Conference on Machine Learning (ICML) (2019)

    Google Scholar 

  20. Jia, Y., Zhang, J., Shan, S., Chen, X.: Single-side domain generalization for face anti-spoofing. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2020)

    Google Scholar 

  21. Karras, T., Laine, S., Aila, T.: A style-based generator architecture for generative adversarial networks. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  22. Kim, T., Kim, Y.: Suppressing spoof-irrelevant factors for domain-agnostic face anti-spoofing. IEEE Access. 9, 86966–86974 (2021)

    Article  Google Scholar 

  23. Kollreider, K., Fronthaler, H., Faraj, M.I., Bigun, J.: Real-time face detection and motion analysis with application in “lliveness” assessment. Trans. Inf. Forens. Secur. (TIFS) 2(3), 548–558 (2007)

    Google Scholar 

  24. Komando, K.: Smartphone security: what’s better to use a pin, facial recognition, or your fingerprint? Fox News (2019)

    Google Scholar 

  25. Komulainen, J., Hadid, A., Pietikäinen, M.: Context based face anti-spoofing. In: International Conference on Biometrics: Theory, Applications and Systems (BTAS) (2013)

    Google Scholar 

  26. Li, L., Feng, X., Boulkenafet, Z., Xia, Z., Li, M., Hadid, A.: An original face anti-spoofing approach using partial convolutional neural network. In: International Conference on Image Processing Theory, Tools and Applications (IPTA) (2016)

    Google Scholar 

  27. Liu, A., Tan, Z., Wan, J., Escalera, S., Guo, G., Li, S.Z.: CASIA-SURF CEFA: a benchmark for multi-modal cross-ethnicity face anti-spoofing. In: Winter Conference on Applications of Computer Vision (WACV) (2021)

    Google Scholar 

  28. Liu, A., et al.: Cross-ethnicity face anti-spoofing recognition challenge: a review. IET Biomet. 10, 24–43 (2020)

    Article  Google Scholar 

  29. Liu, S., Lu, S., Xu, H., Yang, J., Ding, S., Ma, L.: Feature generation and hypothesis verification for reliable face anti-spoofing. In: Association for the Advancement of Artificial Intelligence (AAAI) (2022)

    Google Scholar 

  30. Liu, S., et al.: Adaptive normalized representation learning for generalizable face anti-spoofing. In: ACM International Conference on Multimedia (ACM MM) (2021)

    Google Scholar 

  31. Liu, S., et al.: Dual reweighting domain generalization for face presentation attack detection. In: International Joint Conference on Artificial Intelligence (IJCAI) (2021)

    Google Scholar 

  32. Liu, S., Yuen, P.C., Zhang, S., Zhao, G.: 3D mask face anti-spoofing with remote photoplethysmography. In: Leibe, B., Matas, J., Sebe, N., Welling, M. (eds.) ECCV 2016. LNCS, vol. 9911, pp. 85–100. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-46478-7_6

    Chapter  Google Scholar 

  33. Liu, Y., Jourabloo, A., Liu, X.: Learning deep models for face anti-spoofing: binary or auxiliary supervision. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2018)

    Google Scholar 

  34. Liu, Y., Stehouwer, J., Jourabloo, A., Liu, X.: Deep tree learning for zero-shot face anti-spoofing. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  35. Liu, Y., Stehouwer, J., Liu, X.: On disentangling spoof trace for generic face anti-spoofing. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12363, pp. 406–422. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58523-5_24

    Chapter  Google Scholar 

  36. Liu, Z., Luo, P., Wang, X., Tang, X.: Deep learning face attributes in the wild. In: IEEE International Conference on Computer Vision (ICCV) (2015)

    Google Scholar 

  37. van der Maaten, L., Hinton, G.: Viualizing data using T-SNE. J. Mach. Learn. Res. (JMLR) 9, 2579–2605 (2008)

    MATH  Google Scholar 

  38. Mishra, S.K., Sengupta, K., Horowitz-Gelb, M., Chu, W.S., Bouaziz, S., Jacobs, D.: Improved detection of face presentation attacks using image decomposition. arXiv preprint arXiv:2103.12201 (2021)

  39. Motiian, S., Jones, Q., Iranmanesh, S., Doretto, G.: Few-shot adversarial domain adaptation. In: Neural Information Processing Systems (NeurIPS) (2017)

    Google Scholar 

  40. Motiian, S., Piccirilli, M., Adjeroh, D.A., Doretto, G.: Unified deep supervised domain adaptation and generalization. In: IEEE International Conference on Computer Vision (ICCV) (2017)

    Google Scholar 

  41. Pan, G., Sun, L., Wu, Z., Lao, S.: Eyeblink-based anti-spoofing in face recognition from a generic webcamera. In: IEEE International Conference on Computer Vision (ICCV) (2007)

    Google Scholar 

  42. Patel, K., Han, H., Jain, A.K.: Cross-database face antispoofing with robust feature representation. In: Chinese Conference on Biometric Recognition (CCBR) (2016)

    Google Scholar 

  43. Patel, K., Han, H., Jain, A.K.: Secure face unlock: spoof detection on smartphones. Trans. Inf. Forens. Secur. (TIFS) 11(10), 2268–2283 (2016)

    Article  Google Scholar 

  44. Qin, Y., et al.: Learning meta model for zero-and few-shot face antispoofing. In: Association for the Advancement of Artificial Intelligence (AAAI) (2020)

    Google Scholar 

  45. Ravi, S., Larochelle, H.: Optimization as a model for few-shot learning. In: International Conference on Learning Representations (ICLR) (2017)

    Google Scholar 

  46. Saha, S., et al..: Domain agnostic feature learning for image and video based face anti-spoofing. In: IEEE Conference on Computer Vision and Pattern Recognition Workshops (CVPRW) (2020)

    Google Scholar 

  47. Shao, R., Lan, X., Li, J., Yuen, P.C.: Multi-adversarial discriminative deep domain generalization for face presentation attack detection. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  48. Shao, R., Lan, X., Yuen, P.C.: Regularized fine-grained meta face anti-spoofing. In: Association for the Advancement of Artificial Intelligence (AAAI) (2020)

    Google Scholar 

  49. Snell, J., Swersky, K., Zemel, R.: Prototypical networks for few-shot learning. In: Neural Information Processing Systems (NeurIPS) (2017)

    Google Scholar 

  50. Sung, F., Yang, Y., Zhang, L., Xiang, T., Torr, P.H., Hospedales, T.M.: Learning to compare: Relation network for few-shot learning. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2018)

    Google Scholar 

  51. Teshima, T., Sato, I., Sugiyama, M.: Few-shot domain adaptation by causal mechanism transfer. In: International Conference on Machine Learning (ICML) (2020)

    Google Scholar 

  52. Tseng, H.Y., Lee, H.Y., Huang, J.B., Yang, M.H.: Cross-domain few-shot classification via learned feature-wise transformation. In: International Conference on Learning Representations (ICLR) (2020)

    Google Scholar 

  53. Vinyals, O., Blundell, C., Lillicrap, T., kavukcuoglu, k., Wierstra, D.: Matching networks for one shot learning. In: Neural Information Processing Systems (NeurIPS) (2016)

    Google Scholar 

  54. Wang, G., Han, H., Shan, S., Chen, X.: Cross-domain face presentation attack detection via multi-domain disentangled representation learning. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2020)

    Google Scholar 

  55. Wang, J., Zhang, J., Bian, Y., Cai, Y., Wang, C., Pu, S.: Self-domain adaptation for face anti-spoofing. In: Association for the Advancement of Artificial Intelligence (AAAI) (2021)

    Google Scholar 

  56. Wang, Y.X., Girshick, R., Hebert, M., Hariharan, B.: Low-shot learning from imaginary data. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2018)

    Google Scholar 

  57. Wen, D., Han, H., Jain, A.K.: Face spoof detection with image distortion analysis. Trans. Inf. Forensics Secur. (TIFS) 10(4), 746–761 (2015)

    Article  Google Scholar 

  58. Xu, X., Zhou, X., Venkatesan, R., Swaminathan, G., Majumder, O.: D-SNE: domain adaptation using stochastic neighborhood embedding. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  59. Yang, B., Zhang, J., Yin, Z., Shao, J.: Few-shot domain expansion for face anti-spoofing. arXiv preprint arXiv:2106.14162 (2021)

  60. Yang, J., Lei, Z., Li, S.Z.: Learn convolutional neural network for face anti-spoofing. arXiv preprint arXiv:1408.5601 (2014)

  61. Yang, J., Lei, Z., Liao, S., Li, S.Z.: Face liveness detection with component dependent descriptor. In: International Conference on Biometrics (ICB) (2013)

    Google Scholar 

  62. Yang, X., et al.: Face anti-spoofing: model matters, so does data. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  63. Yu, Z., Li, X., Niu, X., Shi, J., Zhao, G.: Face anti-spoofing with human material perception. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12352, pp. 557–575. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58571-6_33

    Chapter  Google Scholar 

  64. Yu, Z., et al.: Auto-FAS: searching lightweight networks for face anti-spoofing. In: IEEE International Conference on Acoustics, Speech and SP (ICASSP) (2020)

    Google Scholar 

  65. Yu, Z., Wan, J., Qin, Y., Li, X., Li, S., Zhao, G.: NAS-FAS: static-dynamic central difference network search for face anti-spoofing. IEEE Trans. Pattern Recogn. Mach. Intell. (PAMI) 43, 3005–3023 (2021)

    Article  Google Scholar 

  66. Zhang, K.-Y., et al.: Face anti-spoofing via disentangled representation learning. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12364, pp. 641–657. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58529-7_38

    Chapter  Google Scholar 

  67. Zhang, S., et al.: CASIA-surf: a large-scale multi-modal benchmark for face anti-spoofing. In: IEEE Transactions on Biometrics, Behavior, and Identity Science (T-BIOM) (2020)

    Google Scholar 

  68. Zhang, S., et al.: A dataset and benchmark for large-scale multi-modal face anti-spoofing. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR) (2019)

    Google Scholar 

  69. Zhang, X., Meng, D., Gouk, H., Hospedales, T.M.: Shallow Bayesian meta learning for real-world few-shot recognition. In: IEEE International Conference on Computer Vision (ICCV) (2021)

    Google Scholar 

  70. Zhang, Y., et al.: CelebA-spoof: large-scale face anti-spoofing dataset with rich annotations. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12357, pp. 70–85. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58610-2_5

    Chapter  Google Scholar 

  71. Zhang, Z., Yan, J., Liu, S., Lei, Z., Yi, D., Li, S.Z.: A face antispoofing database with diverse attacks. In: International Conference on Biometrics (ICB) (2012)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Hsin-Ping Huang .

Editor information

Editors and Affiliations

1 Electronic supplementary material

Below is the link to the electronic supplementary material.

Supplementary material 1 (pdf 1916 KB)

Rights and permissions

Reprints and permissions

Copyright information

© 2022 The Author(s), under exclusive license to Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Huang, HP. et al. (2022). Adaptive Transformers for Robust Few-shot Cross-domain Face Anti-spoofing. In: Avidan, S., Brostow, G., Cissé, M., Farinella, G.M., Hassner, T. (eds) Computer Vision – ECCV 2022. ECCV 2022. Lecture Notes in Computer Science, vol 13673. Springer, Cham. https://doi.org/10.1007/978-3-031-19778-9_3

Download citation

  • DOI: https://doi.org/10.1007/978-3-031-19778-9_3

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-031-19777-2

  • Online ISBN: 978-3-031-19778-9

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics