Metadata-Version: 2.4
Name: jax-bandflux
Version: 0.3.1
Summary: A JAX-based package for calculating supernovae Bandfluxes
Home-page: https://github.com/samleeney/JAX-bandflux
Author: Samuel Alan Kossoff Leeney
Author-email: sakl2@cam.ac.uk
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Topic :: Scientific/Engineering :: Astronomy
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.24.0
Requires-Dist: jax>=0.4.20
Requires-Dist: jaxlib>=0.4.20
Requires-Dist: sncosmo>=2.9.0
Requires-Dist: pytest>=7.0.0
Requires-Dist: pyyaml>=6.0.0
Requires-Dist: matplotlib
Requires-Dist: tqdm
Requires-Dist: anesthetic
Requires-Dist: requests
Provides-Extra: dev
Requires-Dist: pytest>=6.0; extra == "dev"
Requires-Dist: pytest-cov>=2.0; extra == "dev"
Requires-Dist: black>=22.0; extra == "dev"
Requires-Dist: isort>=5.0; extra == "dev"
Requires-Dist: sphinx>=4.0.0; extra == "dev"
Requires-Dist: sphinx-rtd-theme>=1.0.0; extra == "dev"
Requires-Dist: sphinxcontrib-mermaid>=0.7.0; extra == "dev"
Requires-Dist: sphinx-autodoc-typehints>=1.12.0; extra == "dev"
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: license-file
Dynamic: provides-extra
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

=======================================
``JAX`` Bandflux for Supernovae ``SALT3`` model fitting
=======================================
:Author: Samuel Alan Kossoff Leeney
:version: |pypi version|
:Homepage: https://github.com/samleeney/JAX-bandflux
:Documentation: https://jax-bandflux.readthedocs.io/

.. |PyPI version| image:: https://badge.fury.io/py/jax-bandflux.svg
   :target: https://badge.fury.io/py/jax-bandflux
   :alt: PyPI version

.. image:: https://github.com/samleeney/JAX-bandflux/workflows/Tests/badge.svg
   :target: https://github.com/samleeney/JAX-bandflux/actions
   :alt: Build Status

``JAX-bandflux`` presents an implementation of supernova light curve modelling using ``JAX``. The codebase offers a differentiable approach to core `SNCosmo <https://sncosmo.readthedocs.io/en/stable/>`_ functionality implemented in ``JAX``.

Quickstart
----------

Run example analagous to `SNCosmo <https://sncosmo.readthedocs.io/en/stable/>`_'s "Using a custom fitter" example:

.. code:: bash

   pip install jax-bandflux
   wget https://raw.githubusercontent.com/samleeney/JAX-bandflux/master/examples/fmin_bfgs.py
   python fmin_bfgs.py

Testing
-------

This repository implements the ``JAX`` version of the `SNCosmo <https://sncosmo.readthedocs.io/en/stable/>`_ bandflux function. Although the implementations are nearly identical, a minor difference exists due to the absence of a specific interpolation function in ``JAX``, resulting in a discrepancy of approximately 0.001% in bandflux results. Tests have been provided to confirm that key functions in the `SNCosmo <https://sncosmo.readthedocs.io/en/stable/>`_ version correspond with our ``JAX`` implementation. It is recommended to run these tests, especially following any modifications.

What is the ``.airules`` file?
--------------------------

``.airules``
========

The ``.airules`` file provides essential context to help language models understand
and work with this codebase—particularly for new code that may not be included 
in model training datasets. It contains detailed information on:

- Data structures  
- Core functions  
- Implementation constraints  
- Testing requirements  

If you are using ``cursor``, rename this file to ``.cursorrules`` to enable
automatic context integration.
