Metadata-Version: 2.4
Name: cw_constrain
Version: 0.0.12
Summary: Tools to constrain PBHs and the GeV excess using continuous gravitational waves
Project-URL: Homepage, https://github.com/andrew-l-miller/cw_constrain
Project-URL: Issues, https://github.com/andrew-l-miller/cw_constrain/issues
Project-URL: Documentation, https://github.com/andrew-l-miller/cw_constrain#readme
Project-URL: DOI, https://doi.org/10.5281/zenodo.XXXX
Author-email: "Andrew L. Miller" <andrew.miller.ligo@gmail.com>
License-Expression: MIT AND (Apache-2.0 OR BSD-2-Clause)
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# cw_constrain

[![PyPI version](https://badge.fury.io/py/cw-constrain.svg)](https://pypi.org/project/cw-constrain/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)

---

## Overview

`cw_constrain` is a Python package designed to provide tools and methods for constraining PBH abundance and the MSP hypothesis for the GeV excess using upper limits derived from continuous gravitational wave searches on real LIGO-Virgo-KAGRA data. It includes modules for analyzing GeV excess constraints, primordial black hole constraints, and shared utilities.

---

## Features

- Calculate constraints on MSP luminosity functions that explain the GeV excess using your own luminosity function, your own rotational frequency distribution and/or your own ellipticity distribution.
- Compute constraints on the fraction of dark matter that primordial black hole (PBHs) could compose using your own mass function or PBH formation model.
- Utility functions shared across modules for data processing
- Well-structured package suitable for scientific research and data analysis

---

## GeV excess constraints: how to use your own luminosity function

Please follow the tutorial in `tutorials/O4a_GeV_excess_tutorial.ipynb`

---

## PBH constraints: how to use your own mass functions or PBH formation model


Please follow the tutorial in `tutorials/O4a_pbh_all_sky_tutorial.ipynb`

---


## Installation

You can install the package directly from PyPI:

```bash
pip install cw-constrain

`import cw_constrain` (note the underescore versus hyphen)

