Metadata-Version: 2.4
Name: diffstarpop
Version: 0.0.2
Summary: Library for differentiable generation of star formation histories
Author-email: Alex Alarcon <alexalarcongonzalez@gmail.com>, Andrew Hearin <ahearin@anl.gov>
License: BSD 3-Clause License
        
        Copyright (c) 2024, Andrew Hearin
        All rights reserved.
        
        Redistribution and use in source and binary forms, with or without
        modification, are permitted provided that the following conditions are met:
        
        1. Redistributions of source code must retain the above copyright notice, this
           list of conditions and the following disclaimer.
        
        2. Redistributions in binary form must reproduce the above copyright notice,
           this list of conditions and the following disclaimer in the documentation
           and/or other materials provided with the distribution.
        
        3. Neither the name of the copyright holder nor the names of its
           contributors may be used to endorse or promote products derived from
           this software without specific prior written permission.
        
        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
        AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
        IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
        DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
        FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
        DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
        SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
        CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
        OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
        OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        
Project-URL: home, https://github.com/ArgonneCPAC/diffstarpop
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.11
Description-Content-Type: text/x-rst
License-File: LICENSE.rst
Requires-Dist: diffmah>=0.7.2
Requires-Dist: diffstar>=0.3.3
Requires-Dist: numpy
Requires-Dist: jax
Requires-Dist: dsps
Dynamic: license-file

diffstarpop
============

DiffstarPop is a python library based on JAX for generating statistical realizations 
of the `diffstar <https://diffstar.readthedocs.io/en/latest/>`_ model in
simulation-based forward modeling applications.

Installation
------------
DiffstarPop is currently a private repo that must be installed from source::

    $ cd /path/to/root/diffstarpop
    $ pip install .


Environment configuration
-------------------------
The following step is not required, but we recommend you 

Testing
-------
To run the suite of unit tests::

    $ cd /path/to/root/diffstarpop
    $ pytest

To build html of test coverage::

    $ pytest -v --cov --cov-report html
    $ open htmlcov/index.html

Some of the unit tests require that the DIFFSTARPOP_DRN environment variable is set.
The reason for this is because the data stored in this directory are too large 
to include in the repo and so tests that rely on these data must be run locally.
To create the DIFFSTARPOP_DRN environment variable with the directory 
where the dataset is stored on your disk, add the following line 
to your .bash_profile (for bash users) or .zshrc (for zshell users)::

    export DIFFSTARPOP_DRN="/path/to/drn/containing/diffstarpop/data"
