EUVIMEDEUVIMED entdecken
Open Access · CC BY 4.0

impunity: Enforcing Physical Unit Consistency at Definition Time in Python

Antoine Chevrot, Xavier Olive

Journal of Open Aviation Science · 2023

DOI: 10.59490/joas.2023.7071 ↗

Kurz gefasst

Fachartikel in der Zeitschrift Journal of Open Aviation Science, 2023. Verfasst von Antoine Chevrot und 1 weiteren Autor:innen. Die Arbeit wurde bisher 1-mal zitiert (Crossref). Der Volltext ist frei zugänglich (Open Access, CC BY 4.0).

AbstractBibliografische AngabenZitierenVerwandte Studien

Abstract (Originalsprache)

We introduce impunity, a Python library that enables static analysis of code annotations to ensure the consistency of physical units. It provides a framework for developers to annotate their Python code with physical units and automatically verifies if the units are compatible and adhere to predefined coherence rules. impunity comes as a decorator to apply on functions: it analyses the source code to check for consistency of physical dimensions, and applies minimal code rewriting if conversions are necessary. Overall, this approach takes the best of type-checking based methods and dynamic methods and provides a robust approach with no overhead at runtime.

Zitieren

APA

Chevrot, A., & Olive, X. (2023). impunity: Enforcing Physical Unit Consistency at Definition Time in Python. Journal of Open Aviation Science. https://doi.org/10.59490/joas.2023.7071

Vancouver

Chevrot A, Olive X. impunity: Enforcing Physical Unit Consistency at Definition Time in Python. Journal of Open Aviation Science. 2023. doi:10.59490/joas.2023.7071

BibTeX
@article{Chevrot2023,
  author = {Chevrot, Antoine and Olive, Xavier},
  title = {impunity: Enforcing Physical Unit Consistency at Definition Time in Python},
  journal = {Journal of Open Aviation Science},
  year = {2023},
  doi = {10.59490/joas.2023.7071}
}
Kostenlos starten →