# SetMargin Loss applied to Deep Keystroke Biometrics with Circle Packing Interpretation

arXiv: https://arxiv.org/abs/2109.00938 · HTML: https://mlsanity.com/paper/2109.00938/

## Key facts

- Cited by 11 papers in the map (data through 14 Oct 2026).
- Builds on 13 of its 38 references that are in the map.
- First posted on arXiv 2 Sep 2021.

## Builds on (most cited first, 13 of 13)

- [Very Deep Convolutional Networks for Large-Scale Image Recognition](https://mlsanity.com/paper/1409.1556/) (2014)
- [FaceNet: A Unified Embedding for Face Recognition and Clustering](https://mlsanity.com/paper/1503.03832/) (2015)
- [In Defense of the Triplet Loss for Person Re-Identification](https://mlsanity.com/paper/1703.07737/) (2017)
- [A Neural Representation of Sketch Drawings](https://mlsanity.com/paper/1704.03477/) (2017)
- [Large-Margin Softmax Loss for Convolutional Neural Networks](https://mlsanity.com/paper/1612.02295/) (2016)
- [Scalable Bayesian Optimization Using Deep Neural Networks](https://mlsanity.com/paper/1502.05700/) (2015)
- [Beyond triplet loss: a deep quadruplet network for person re-identification](https://mlsanity.com/paper/1704.01719/) (2017)
- [Metric Learning with Adaptive Density Discrimination](https://mlsanity.com/paper/1511.05939/) (2015)
- [Actions Speak Louder Than (Pass)words: Passive Authentication of Smartphone Users via Deep Temporal Features](https://mlsanity.com/paper/1901.05107/) (2019)
- [Deep Linear Discriminant Analysis on Fisher Networks: A Hybrid Architecture for Person Re-identification](https://mlsanity.com/paper/1606.01595/) (2016)
- [Keystroke Biometrics in Response to Fake News Propagation in a Global Pandemic](https://mlsanity.com/paper/2005.07688/) (2020)
- [Robust Keystroke Biometric Anomaly Detection](https://mlsanity.com/paper/1606.09075/) (2016)
- [TypeNet: Scaling up Keystroke Biometrics](https://mlsanity.com/paper/2004.03627/) (2020)

## Built on by (most cited first, 11 of 11)

- [Measuring Bias in AI Models: An Statistical Approach Introducing N-Sigma](https://mlsanity.com/paper/2304.13680/) (2023)
- [Keystroke Verification Challenge (KVC): Biometric and Fairness Benchmark Evaluation](https://mlsanity.com/paper/2311.06000/) (2023)
- [Type2Branch: Keystroke Biometrics based on a Dual-branch Architecture with Attention Mechanisms and Set2set Loss](https://mlsanity.com/paper/2405.01088/) (2024)
- [BeCAPTCHA-Type: Biometric Keystroke Data Generation for Improved Bot Detection](https://mlsanity.com/paper/2207.13394/) (2022)
- [IEEE BigData 2023 Keystroke Verification Challenge (KVC)](https://mlsanity.com/paper/2401.16559/) (2024)
- [KVC-onGoing: Keystroke Verification Challenge](https://mlsanity.com/paper/2412.20530/) (2024)
- [Is It Really You? Exploring Biometric Verification Scenarios in Photorealistic Talking-Head Avatar Videos](https://mlsanity.com/paper/2508.00748/) (2025)
- [VideoRun2D: Cost-Effective Markerless Motion Capture for Sprint Biomechanics](https://mlsanity.com/paper/2409.10175/) (2024)
- [Balancing Tails when Comparing Distributions: Comprehensive Equity Index (CEI) with Application to Bias Evaluation in Operational Face Biometrics](https://mlsanity.com/paper/2506.10564/) (2025)
- [Free-text Keystroke Authentication using Transformers: A Comparative Study of Architectures and Loss Functions](https://mlsanity.com/paper/2310.11640/) (2023)
- [EERLoss: A Novel Loss Function for Training Deep Biometric Models. A Case Study in Keystroke Dynamics](https://mlsanity.com/paper/2606.24586/) (2026)

## Abstract (arXiv)

This work presents a new deep learning approach for keystroke biometrics based on a novel Distance Metric Learning method (DML). DML maps input data into a learned representation space that reveals a "semantic" structure based on distances. In this work, we propose a novel DML method specifically designed to address the challenges associated to free-text keystroke identification where the classes used in learning and inference are disjoint. The proposed SetMargin Loss (SM-L) extends traditional DML approaches with a learning process guided by pairs of sets instead of pairs of samples, as done traditionally. The proposed learning strategy allows to enlarge inter-class distances while maintaining the intra-class structure of keystroke dynamics. We analyze the resulting representation space using the mathematical problem known as Circle Packing, which provides neighbourhood structures with a theoretical maximum inter-class distance. We finally prove experimentally the effectiveness of the proposed approach on a challenging task: keystroke biometric identification over a large set of 78,000 subjects. Our method achieves state-of-the-art accuracy on a comparison performed with the best existing approaches.
