-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
software packaging shell without any code
- Loading branch information
Showing
9 changed files
with
159 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [3.8] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install --upgrade pytest | ||
python -m pip install flake8 pytest pytest-cov coveralls | ||
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi | ||
if [ -f test_requirements.txt ]; then pip install -r test_requirements.txt; fi | ||
python -m pip install . | ||
#- name: Lint with flake8 | ||
# run: | | ||
# stop the build if there are Python syntax errors or undefined names | ||
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics | ||
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide | ||
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics | ||
- name: Test with pytest | ||
run: | | ||
pytest --cov=jaxtronomy | ||
- name: Coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
coveralls --service=github |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
======= | ||
Credits | ||
======= | ||
|
||
|
||
lenstronomy contributors | ||
------------------------ | ||
|
||
See the `lenstronomy contributors list <https://github.com/lenstronomy/lenstronomy/blob/main/AUTHORS.rst>`_ on the `lenstronomy <https://github.com/lenstronomy/lenstronomy>`_ repository | ||
for a full list of contirbutors to the original lenstronomy source code. | ||
|
||
|
||
|
||
Contributors to the JAXtronomy | ||
------------------------------ | ||
|
||
* Aymeric Galan `aymgal <https://github.com/aymgal/>`_ | ||
* Simon Birrer `sibirrer <https://github.com/sibirrer/>`_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Citation Guidelines | ||
=================== | ||
|
||
|JOSS| | ||
|
||
If you use JAXtronomy for work or research presented in a publication (whether | ||
directly, or as a dependency of another package) we recommend and encourage | ||
the following acknowledgment: | ||
|
||
This research made use of lenstronomy, a multi-purpose gravitational lens | ||
modeling software package (Birrer et. al., 2021). | ||
|
||
where the citations are to our publication in the `Journal of Open Source | ||
Software`_. We also encourage citations within the main text wherever | ||
appropriate. DOIs and BibTeX keys are available through the links above. | ||
|
||
|
||
.. _Journal of Open Source Software: https://joss.theoj.org/papers/10.21105/joss.03283 | ||
|
||
.. |JOSS| image:: https://joss.theoj.org/papers/10.21105/joss.03283/status.svg | ||
:target: https://joss.theoj.org/papers/10.21105/joss.03283 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
========== | ||
JAXtronomy | ||
========== | ||
|
||
.. image:: https://github.com/lenstronomy/JAXtronomy/workflows/Tests/badge.svg | ||
:target: https://github.com/lenstronomy/JAXtronomy/actions | ||
|
||
.. image:: https://img.shields.io/badge/License-BSD_3--Clause-blue.svg | ||
:target: https://github.com/lenstronomy/lenstronomy/blob/main/LICENSE | ||
|
||
|
||
|
||
**JAX port of lenstronomy, for parallelized, GPU accelerated, and differentiable gravitational lensing and image simulations.** | ||
|
||
**Disclaimer**: This project is still in an early development phase and serves as a skeleton for someone taking the lead on it :) | ||
|
||
The goal of this library is to reimplement lenstronomy functionalities in pure JAX to allow for automatic differentiation, GPU acceleration, and batched computations. | ||
|
||
**Guiding Principles**: | ||
|
||
- Strive to be a drop-in replacement for lenstronomy, i.e. provide a close match to the lenstronomy API. | ||
- Each function/feature will be tested against the reference lenstronomy implementation. | ||
- This package will aim to be a **subset** of lenstronomy (i.e. only contains functions with a reference lenstronomy implementation). | ||
- Implementations should be easy to read and understand. | ||
- Code should be pip installable on any machine, no compilation required. | ||
- Any notable differences between the JAX and reference implementations will be clearly documented. | ||
|
||
|
||
|
||
Related software packages | ||
------------------------- | ||
|
||
The following lensing software packages do use JAX-accelerated computing that in part were inspired or made use of lenstronomy functions: | ||
|
||
- Herculens_ | ||
- GIGA-lens_ | ||
|
||
.. _Herculens: https://github.com/austinpeel/herculens | ||
.. _GIGA-lens: https://github.com/giga-lens/gigalens | ||
|
||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
__author__ = 'lenstronomy developers' | ||
__version__ = '0.0.1rc1' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
from setuptools import setup, find_packages | ||
|
||
requires = ["numpy >= 1.18.0", "lenstronomy >= 1.10.4", "jax", "jaxlib"] | ||
tests_require = ["pytest"] | ||
|
||
setup( | ||
name="JAX-lenstronomy", | ||
version="0.0.1rc1", | ||
url="https://github.com/lenstronomy/JAX-lenstronomy", | ||
author="lenstronomy developers", | ||
description="lenstronomy, but in JAX", | ||
packages=find_packages(), | ||
license="BSD-3", | ||
install_requires=requires, | ||
tests_require=tests_require, | ||
keywords='lenstronomy', | ||
classifiers=[ | ||
"Development Status :: 1 - Alpha", | ||
"Intended Audience :: Science/Research", | ||
"Natural Language :: English", | ||
"Operating System :: OS Independent", | ||
"Programming Language :: Python", | ||
"Programming Language :: Python :: 3.8", | ||
"Programming Language :: Python :: 3.9", | ||
], | ||
) |
Empty file.