Skip to main content

History of astronomy library

Project description

GitHub Pipeline Status Coverage Docs status Kanon Pypi Python 3.8 Powered by Astropy Badge

Kanon is the History of Astronomy Python package and tools.

Current Features


  • Define standard positional numeral systems with standard arithmetics (BasedReal)

  • Set your own precision contexts and algorithms on arithmetical operations (PrecisionContext)

  • Keep track of all operations


  • Build or import ancient astronomical tables

  • Perform arithmetical and statistical operations

  • Support for BasedReal values


  • Define new calendar types

  • Date conversions


  • Collection of mathematical models used for all kinds of geocentric astronomical tables

How to use

Install the package with pip

pip install kanon

Import Kanon and begin trying all its features

import kanon.units as u

a = u.Sexagesimal(1,2,3)
b = u.Sexagesimal(2,1,59)

a + b
# 3,4,2 ;


To start developing on this project you need to install the package with poetry (Installing Poetry <>)

git clone
cd kanon
poetry install

The changes you make in the code are reflected on your Python environment.

Activate pre-commit checks :

pre-commit install


Run tests with tox

# source code tests
tox -e test

# example notebooks tests
tox -e test_notebooks

# linting
pre-commit run --all-files

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kanon-0.6.5.tar.gz (46.6 kB view hashes)

Uploaded source

Built Distribution

kanon-0.6.5-py3-none-any.whl (52.0 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page