{"id":46588669,"url":"https://github.com/timmh/biolith","last_synced_at":"2026-03-07T13:02:59.232Z","repository":{"id":280954339,"uuid":"924294950","full_name":"timmh/biolith","owner":"timmh","description":"Bayesian Ecological Modeling in Python","archived":false,"fork":false,"pushed_at":"2026-02-23T20:39:48.000Z","size":7973,"stargazers_count":29,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-02-24T00:24:35.890Z","etag":null,"topics":["bayesian","ecology","numpyro","occupancy-modeling"],"latest_commit_sha":null,"homepage":"https://timm.haucke.xyz/biolith/","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/timmh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-01-29T18:48:33.000Z","updated_at":"2026-02-23T20:39:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"f8d7d312-f7b7-4353-84bb-a1f2709d95c4","html_url":"https://github.com/timmh/biolith","commit_stats":null,"previous_names":["timmh/biolith"],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/timmh/biolith","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timmh%2Fbiolith","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timmh%2Fbiolith/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timmh%2Fbiolith/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timmh%2Fbiolith/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/timmh","download_url":"https://codeload.github.com/timmh/biolith/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timmh%2Fbiolith/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30214618,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T12:15:00.571Z","status":"ssl_error","status_checked_at":"2026-03-07T12:15:00.217Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bayesian","ecology","numpyro","occupancy-modeling"],"created_at":"2026-03-07T13:02:59.173Z","updated_at":"2026-03-07T13:02:59.224Z","avatar_url":"https://github.com/timmh.png","language":"Jupyter Notebook","readme":"# \u003cimg alt=\"Biolith logo\" src=\"assets/biolith.svg\" style=\"height: 2em;\"\u003e Biolith: \u003cins\u003eB\u003c/ins\u003eayes\u003cins\u003ei\u003c/ins\u003ean Ec\u003cins\u003eol\u003c/ins\u003eogical Modeling \u003cins\u003ei\u003c/ins\u003en Py\u003cins\u003eth\u003c/ins\u003eon\n\n[![Test](https://github.com/timmh/biolith/actions/workflows/test.yml/badge.svg)](https://github.com/timmh/biolith/actions/workflows/test.yml) [![PyPI - Version](https://img.shields.io/pypi/v/biolith)](https://pypi.org/project/biolith/) [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.15706627.svg)](https://doi.org/10.5281/zenodo.15706627)\n\nBiolith is a Python package designed for Bayesian ecological modeling and analysis with a focus on occupancy modeling. It has similar goals to [Unmarked](https://github.com/biodiverse/unmarked) and [spOccupancy](https://github.com/biodiverse/spOccupancy/), but is written in Python and uses [NumPyro](https://num.pyro.ai) and [JAX](https://jax.readthedocs.io) to enable rapid model fitting and iteration.\n\n## Features\n\n- **Hackable**: Models are easy to understand and implement, no likelihood derivations needed.\n- **Fast**: Models can be fit on GPUs, which is _fast_.\n- **Familiar**: Everything is written in Python, making it easy to integrate into existing pipelines.\n\n## Installation\n\nInstall Biolith using pip:\n\n```bash\npip install biolith\n```\n\n### Accelerator support\n\nFor NVIDIA GPU support, check your CUDA version with `nvidia-smi` and install the corresponding JAX variant:\n\n```bash\n# CUDA 13.x\npip install biolith[cuda13]\n```\n\nFor AMD GPUs:\n```bash\npip install biolith[rocm]\n```\n\nFor Google Cloud TPU VMs:\n```bash\npip install biolith[tpu]\n```\n\n## Usage\n\nHere is a simple example using simulated data to get you started:\n\n```python\nfrom biolith.models import occu, simulate\nfrom biolith.utils import fit\n\n# Simulate dataset\ndata, true_params = simulate()\n\n# Fit model to simulated data\nresults = fit(occu, **data)\n\n# Compare estimated occupancy probability to the true mean occupancy\nprint(f\"Mean estimated psi: {results.samples['psi'].mean():.2f}\")\nprint(f\"Mean true occupancy: {true_params['z'].mean():.2f}\")\n```\n\n## Real-world Example\nTo see a real-world example on camera trap data, see [this Jupyter Notebook](./assets/CameraTrapExample.ipynb) from the [EFI Statistical Methods Seminar Series](https://github.com/eco4cast/Statistical-Methods-Seminar-Series/tree/main/beery-haucke_biolith) or [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/timmh/biolith/blob/main/assets/CameraTrapExample.ipynb)\n\n## Documentation\nAPI Documentation and examples are available [here](https://timm.haucke.xyz/biolith/).\n\n## Development\n\nMake sure to install development dependencies, e.g. using:\n\n```bash\npip install -e \".[dev]\"\n```\n\nRun `pytest` to run unit tests.\n\nRun `scripts/format.sh` to format the codebase. Execute `scripts/check.sh` to run\nisort, docformatter and black in check mode along with pylint and pyright.\n\nTo install the pre-commit hook for formatting and code linting, run:\n\n```bash\n./scripts/install_precommit.sh\n```\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n## Contact\n\nFor questions or feedback, please open an issue or email [haucke@mit.edu](mailto:haucke@mit.edu).\n\n## Acknowledgements\nThis work was supported by the AI and Biodiversity Change (ABC) Global Center, which is funded by the [US National Science Foundation under Award No. 2330423](https://www.nsf.gov/awardsearch/showAward?AWD_ID=2330423\u0026HistoricalAwards=false) and [Natural Sciences and Engineering Research Council of Canada under Award No. 585136](https://www.nserc-crsng.gc.ca/ase-oro/Details-Detailles_eng.asp?id=782440). This work draws on research supported in part by the Social Sciences and Humanities Research Council.","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimmh%2Fbiolith","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftimmh%2Fbiolith","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimmh%2Fbiolith/lists"}