Skip to main content

astro-mmdc

Python SDK for the MMDC astrophysics platform: multi-wavelength SED data, on-demand Swift UVOT/XRT analysis and blazar broadband emission modeling.

PyPI Python versions License Tests Docs DOI

The Markarian Multiwavelength Data Center (MMDC) gathers multi-wavelength, multi-epoch observations of blazars and other sources from dozens of catalogues and archives. It also models their broadband emission with SSC, EIC and hadronic models, and this SDK gives Python access to all of it.

Installation

pip install astro-mmdc

Or with uv:

uv pip install astro-mmdc

Requires Python 3.10+. Plotting needs the extra: pip install "astro-mmdc[plot]".

Quick start

from astro_mmdc import MMDC

client = MMDC()

# The SED of 3C 273: source info plus every point
sed = client.sed.get(ra=187.2779, dec=2.0524, name="3C 273")
print(sed.source.redshift, sed.points)
sed.to_csv("3c273.csv")

# A synchronous SSC model spectrum
result = client.modeling.infer(
    z=0.158, ebl=True, model_type="SSC",
    parameters={"log_B": -1.5, "log_electron_luminosity": 44.0,
                "log_gamma_cut": 5.0, "log_gamma_min": 2.0,
                "log_radius": 16.0, "lorentz_factor": 20.0,
                "spectral_index": 2.2},
)
print(result.nu, result.nuFnu)

The Getting started page has more examples, including a full SED-to-fit pipeline.

What you can do

  • SED data: the SED at any sky position, with filters, unit conversion, CSV export and plots. See the SED data guide.
  • Observations and light curves: filtered queries and cone searches over the unified observations catalogue (Fermi, Swift, NuSTAR, ZTF, ASAS-SN, ...). See the observations guide.
  • Swift UVOT/XRT analysis: on-demand photometry and XRT spectral fits through the MADAM pipeline, with a coverage cache. See the Swift guide.
  • Blazar emission modeling: SSC, EIC and hadronic model fits and synchronous inference. See the modeling guide.
  • Async jobs: submit SED, modeling and Swift jobs, then poll them yourself. See Advanced.

Citing

If you use MMDC data, models or this SDK in your research, please cite the MMDC paper (Sahakyan et al. 2024, AJ, 168, 289; doi:10.3847/1538-3881/ad8231):

@article{Sahakyan_2024,
  title     = {Markarian Multiwavelength Data Center (MMDC): A Tool for Retrieving and Modeling Multitemporal, Multiwavelength, and Multimessenger Data from Blazar Observations},
  author    = {Sahakyan, N. and Vardanyan, V. and Giommi, P. and B{\'e}gu{\'e}, D. and Israyelyan, D. and Harutyunyan, G. and Manvelyan, M. and Khachatryan, M. and Dereli-B{\'e}gu{\'e}, H. and Gasparyan, S.},
  journal   = {The Astronomical Journal},
  publisher = {American Astronomical Society},
  volume    = {168},
  number    = {6},
  pages     = {289},
  year      = {2024},
  month     = nov,
  doi       = {10.3847/1538-3881/ad8231},
  eprint    = {2410.01207},
  archivePrefix = {arXiv}
}

Data retrieved through MMDC is licensed under CC BY 4.0 and requires attribution. The SDK itself is archived on Zenodo, doi:10.5281/zenodo.22999175 (all versions); its citation metadata is in CITATION.cff.

License

BSD-3-Clause, see LICENSE.

Metadata

Release files for astro-mmdc 0.2.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for astro-mmdc 0.2.10
File Size Uploaded
astro_mmdc-0.2.10.tar.gz 31.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for astro-mmdc 0.2.10
File Interpreter ABI Platform
astro_mmdc-0.2.10-py3-none-any.whl Python 3 none any Details

Total release size: 69.9 kB

Release files / astro_mmdc-0.2.10.tar.gz

Download URL astro_mmdc-0.2.10.tar.gz
Size 31.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d108c4d4a9eba9d3f6f57398c45d048a9f72a70bd6ea35ad15e9cba8999e791e
BLAKE2b-256 checksum
How to use checksums
2af8f7947a06b677fada02640714c700740d99f6cc53cdb93897360251c8b56e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / astro_mmdc-0.2.10-py3-none-any.whl

Download URL astro_mmdc-0.2.10-py3-none-any.whl
Size 38.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
acc8452d0e652fe90480969bdec05e7c9d1fb29bd7afb9941499c672130e5547
BLAKE2b-256 checksum
How to use checksums
6652fc5e2bfd603dca5d02cd231051ea20bd50ed8b6f0bb42be225a8e66f9a4a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

This release

0.2.10 This release

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release 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