Skip to main content
Latest PyPI version Latest arXiv release Latest GitHub release

Gradient Informed, GPU Accelerated Lens modelling (GIGA-Lens) is a package for fast and rigorous Bayesian inference on strong gravitational lenses, with support for multi-device and multi-node GPU acceleration for large-scale inference workloads. For details, please see our original paper and our latest paper <https://arxiv.org/abs/2606.30633>. Documentation is provided here.

Note: Documentation follows our Github release, which will be updated pending paper acceptance

Installation

GIGA-Lens can be installed via pip:

pip install gigalens[cuda]

the cuda extension is recommended to ensure If you wish to test the installation, tests can be run simply by running tox in the root directory.

If you don’t have access to institutional GPUs, one easy way is to use GPU on Google Colab. Please remember the very first cell should have !pip install gigalens[cuda].

If you do have access to institutional GPUs, you can set up a notebook to run on GPU. For example, at NESRC, for running GIGA-Lens on a single GPU node, you can choose the kernel tensorflow-2.6.0, and include in the first cell: !pip install gigalens[cuda].

Demo Notebooks

The notebooks below demonstrate some examples of lens modeling with JAX and Tensorflow respectively. For the quickstart notebooks, you can run them directly using Google Colab.

Requirements

Python Version >= 3.12

The following packages are requirements for GIGA-Lens. However, we recommend using pip to avoid issues with subpackage dependencies.

  • jax==0.6.2

  • tensorflow-probability==0.25.0

  • lenstronomy>=1.13.2,<2.0.0

  • optax>=0.2.6,<0.3.0

  • objax>=1.8.0,<2.0.0

  • numpy>=2.0.2

  • tqdm>=4.67.1,<5.0.0

Authors

GIGALens was written by Andi Gu in 2021, and is developed by:

Cite:

Latest arXiv release
@misc{huang2026gigalens20stronglensmodeling,
    title={GIGA-Lens 2.0: Strong-Lens Modeling on Multiple GPU Nodes},
    author={Xiaosheng Huang and Linus Upson and Nicolas Ratier-Werbin and Harry Lu and Sean Xu and Elden Yap and Evan Odell and Ansel Parke and Harsh Ambardekar and Saul Baltasar and Nestor Demeure and Bradley Richardson and Andi Gu and Yuan-Ming Hsu and Junyi Liu},
    year={2026},
    eprint={2606.30633},
    archivePrefix={arXiv},
    primaryClass={astro-ph.CO},
    url={https://arxiv.org/abs/2606.30633},
}

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gigalens-2.0.tar.gz (335.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gigalens-2.0-py3-none-any.whl (345.2 kB view details)

Uploaded Python 3

File details

Details for the file gigalens-2.0.tar.gz.

File metadata

  • Download URL: gigalens-2.0.tar.gz
  • Upload date:
  • Size: 335.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for gigalens-2.0.tar.gz
Algorithm Hash digest
SHA256 564877b4b407030a9661304e4a4e1f170ac2923cf8ca19f4022ffd488a650d11
MD5 6f26850424f1f13c61d217a7b93e7776
BLAKE2b-256 d4ab30fb71b433d963fd3042bdf857e20415f75e7676913962b3289672c096f6

See more details on using hashes here.

File details

Details for the file gigalens-2.0-py3-none-any.whl.

File metadata

  • Download URL: gigalens-2.0-py3-none-any.whl
  • Upload date:
  • Size: 345.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for gigalens-2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1e3aa895981b499d2003b3813864452bbbb000e9233c03e52126f28a03481c73
MD5 f80740861c8b13cd1e675c15e3522f83
BLAKE2b-256 5830b419f4ed0751617168e14b1aea5da30b2d1f80b3683169562be9d48b3de7

See more details on using hashes here.

Release history Release notifications | RSS feed

2.0.1

2 files

This release

2.0 This release

2 files

1.2.1

2 files

1.2.0

2 files

1.1.0

2 files

0.1.8

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page