# pyCANON: A Python library to check the level of anonymity of a dataset

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

## Key facts

- Cited by 2 papers in the map (data through 14 Oct 2026).
- First posted on arXiv 16 Aug 2022.

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

- [Comparison of machine learning models applied on anonymized data with different techniques](https://mlsanity.com/paper/2305.07415/) (2023)
- [Privacy Preserving Machine Learning Workflow: from Anonymization to Personalized Differential Privacy Budgets in Federated Learning](https://mlsanity.com/paper/2605.02372/) (2026)

## Abstract (arXiv)

Openly sharing data with sensitive attributes and privacy restrictions is a challenging task. In this document we present the implementation of pyCANON, a Python library and command line interface (CLI) to check and assess the level of anonymity of a dataset through some of the most common anonymization techniques: k-anonymity, (α,k)-anonymity, ℓ-diversity, entropy ℓ-diversity, recursive (c,ℓ)-diversity, basic β-likeness, enhanced β-likeness, t-closeness and δ-disclosure privacy. For the case of more than one sensitive attributes, two approaches are proposed for evaluating this techniques. The main strength of this library is to obtain a full report of the parameters that are fulfilled for each of the techniques mentioned above, with the unique requirement of the set of quasi-identifiers and that of sensitive attributes. We present the methods implemented together with the attacks they prevent, the description of the library, use examples of the different functions, as well as the impact and the possible applications that can be developed. Finally, some possible aspects to be incorporated in future updates are proposed.
