Analysis and archiving of archaeological dating evidence
Project description
PolyChron
PolyChron is a GUI application designed to facilitate the analysis and archiving of archaeological dating evidence. It supports the management of both relative and absolute dating evidence, enabling users to build multiple chronological models within a Bayesian modelling framework.
Key features include:
-
Graph-theoretic representations of stratigraphic sequences, which users can explore and edit via an intuitive point-and-click interface.
-
The ability to input prior knowledge, such as:
-
Groupings of archaeological contexts
-
Identification of residual or intrusive samples
-
Relationships between different groups
-
Using this information, PolyChron constructs a hierarchical Bayesian model and uses an MCMC (Markov Chain Monte Carlo) algorithm to estimate the posterior calendar ages of samples.
All outputs, including raw digital data (as input by the user), model representations, results, and supplementary notes are saved locally. This ensures the full site archive is preserved for future use and long-term archiving with the Archaeology Data Service.
Documentation
For full documentation including a userguide and developer reference, please see bryonymoody.github.io/PolyChron.
Installation
PolyChron is a GUI application written in python using tkinter.
If you are familiar with python, polychron can be installed using pip, and Graphviz must be installed on your system.
Requirements
polychron is a Python package which uses Graphviz for graph rendering.
Before you install polychron, you should ensure a compatible version of python is available (with pip, tkinter and ideally venv) and should install graphviz.
-
3.9-3.13
-
- which you can install manually) or through your system package manager:
- Linux
# debian, ubuntu, etc. sudo apt install graphviz # fedora, RHEL, Rocky, etc. sudo dnf install graphviz
- macOS
# using brew (if installed) brew install graphviz
- Windows
# using chocolatey (if installed) choco install graphviz --no-progress -y
- Linux
- which you can install manually) or through your system package manager:
-
- Although
tkinteris part of the Python3 standard library, it is not included in all pre-compiled python distributions. If you encounter errors related to importingtkinter, you may need to install it. - linux
# e.g. for Ubuntu/Debian apt-get install python3-tk
- macOS
# using brew (if python was installed with brew) brew install python-tk
- Although
Installing polychron from PyPI
polychron is a Python package and released versions of polychron can be installed from PyPI using pip, ideally in a virtual environment.
python3 -m pip install polychron
Installing polychron from Source
It is recommended to use a Python virtual environment (venv) or similar for installations of polychron from source, for example:
# Create and activate a venv
python3 -m venv .venv
source .venv/bin/activate
polychron can be installed from source using pip and git, using the latest development version or specific releases.
# Install the current development version
python3 -m pip install git+https://github.com/bryonymoody/PolyChron.git
# Install a tagged release or branch, in this case v0.2.0
python3 -m pip install git+https://github.com/bryonymoody/PolyChron.git@v0.2.0
Or by cloning the git repository from GitHub and installing into the current python environment.
git clone https://github.com/bryonymoody/PolyChron
cd PolyChron
python3 -m pip install .
[!TIP] If you are installing PolyChron from source as a developer, consider using an editable installation (
-e/--editable) and installing thedev,docandtestextras.python3 -m pip install -e .[dev,doc,test]
Usage
With PolyChron installed in the current python environment, it can be launched using any of the following:
# via the executable script
polychron
# or by running the installed polychron module
python3 -m polychron
License
PolyChron is released under the GPLv3 license
Contributing
If you would like to contribute towards PolyChron, please see the contributing guidelines.
Linting
Linting is handled using ruff which can be installed as part of the dev extras.
Ruff can then be invoked using:
python3 -m ruff check
# or
ruff check
Formatting
Automatic code formatting is handled using ruff which can be installed as part of the dev extras.
Ruff can then be invoked using:
python3 -m ruff fromat
# or
ruff format
This can be automatically applied on commit through pre-commit hooks
Testing
Tests are implemented using pytest, which can be installed as part of the test optional dependencies via:
python3 -m pip install .[test]
Once installed, unit tests can be executed via pytest from the root directory
python3 -m pytest
# or
pytest
Building Documentation
Documentation is built using mkdocs and some extensions.
Documentation building dependencies are included in the doc optional dependencies group.
They can be installed into the current python environment along with polychron using pip:
python3 -m pip install -e .[doc]
Once installed, documentation can be generated and viewed via a local webserver using:
python3 -m mkdocs serve
# or just
mkdocs serve
Or a static html version can be built into _site using:
python3 -m mkdocs build
# pass --no-directory-urls if you wish to view local .html files without a web server
python3 -m mkdocs build --no-directory-urls
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file polychron-0.2.0.tar.gz.
File metadata
- Download URL: polychron-0.2.0.tar.gz
- Upload date:
- Size: 2.8 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b4893fe8ade2d72099764531dd8b5273b1131ec23fea057d1d4c1a41a4d98219
|
|
| MD5 |
bb583ba5bd40d7c5fd02bac3620a16c3
|
|
| BLAKE2b-256 |
886e30d1bd9600fb027a7c2c18bcd6334c2e3c210da33185ada5e62792a16e88
|
Provenance
The following attestation bundles were made for polychron-0.2.0.tar.gz:
Publisher:
publish.yml on bryonymoody/PolyChron
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
polychron-0.2.0.tar.gz -
Subject digest:
b4893fe8ade2d72099764531dd8b5273b1131ec23fea057d1d4c1a41a4d98219 - Sigstore transparency entry: 487566605
- Sigstore integration time:
-
Permalink:
bryonymoody/PolyChron@d1a6d5e2a461229d34487cdf5c2125f3a0967602 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/bryonymoody
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d1a6d5e2a461229d34487cdf5c2125f3a0967602 -
Trigger Event:
push
-
Statement type:
File details
Details for the file polychron-0.2.0-py3-none-any.whl.
File metadata
- Download URL: polychron-0.2.0-py3-none-any.whl
- Upload date:
- Size: 1.6 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5bbe6d02a25dae6d108e421fc6803799fc6cb23e18de49b1e56cdcaf89f8e7b3
|
|
| MD5 |
1acc38837cf72f194eff6ec8335b7fa7
|
|
| BLAKE2b-256 |
33f4b56687f8cf20aac09c16fae615e89602134f37b67188293f49cc4259f936
|
Provenance
The following attestation bundles were made for polychron-0.2.0-py3-none-any.whl:
Publisher:
publish.yml on bryonymoody/PolyChron
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
polychron-0.2.0-py3-none-any.whl -
Subject digest:
5bbe6d02a25dae6d108e421fc6803799fc6cb23e18de49b1e56cdcaf89f8e7b3 - Sigstore transparency entry: 487566629
- Sigstore integration time:
-
Permalink:
bryonymoody/PolyChron@d1a6d5e2a461229d34487cdf5c2125f3a0967602 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/bryonymoody
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d1a6d5e2a461229d34487cdf5c2125f3a0967602 -
Trigger Event:
push
-
Statement type: