Skip to main content

MeerKAT primary beam model handling utilities

Project description

suricat-beams

MeerKAT primary beam model handling utilities

See https://doi.org/10.48479/wdb0-h061 for documentation on beam models.

The utilities can download the models for you automatically, see suricat-beams/suricat/recipes/init.yml Stimela recipe.

Installation

Use pip install suricat-beams for the full package.

Use pip install suricat-beams-cabs to install Stimela cab definitions only.

CLI commands

All commands are accessible via the suricat CLI:

suricat download U                      # Download U-band beam model
suricat mdv2bds input.npz output.bds    # Convert MdV npz to beam dataset
suricat bds2xradio beam.bds.zarr image.zarr output.zarr \
    --output-var SKY \
    --pixel-stepping 4 --time-stepping 4 \
    --num-freq 8 --chunks-time 1 --chunks-freq 1 \
    --polarizations I --beam-type nstokes       # Render BDS to xradio zarr
suricat mdv2xradio mdv-beams-L.npz output.zarr \
    --antenna -1 --jones HH --part real \
    --output-var SKY                            # Convert MdV npz to xradio zarr

Output format

Both xradio tools produce zarr datasets following the xradio image schema:

Dimensions:   (time, frequency, polarization, l, m)
Coordinates:  time (MJD), frequency (Hz), polarization (str), l (rad), m (rad)
Data vars:    <var_name> (time, frequency, polarization, l, m) float32
Attributes:   direction (reference, latpole, lonpole, projection, pc)

Stimela integration

Stimela cab definitions are in suricat-beams/suricat/cabs/suricat.yml:

  • suricat.download-mdv-beams -- download MdV beams from SARAO archive
  • suricat.mdv-beams-to-bds -- convert MdV npz to beam dataset
  • suricat.bds-to-xradio -- render BDS to xradio zarr image
  • suricat.mdv-to-xradio -- convert MdV npz to xradio zarr image
stimela run suricat-beams/suricat/recipes/init.yml suricat-init band=U

Python API

from suricat.xradio_util import bds_to_xradio, mdv_to_xradio

# Render a BDS with observational context
bds_to_xradio("beam.bds.zarr", "image.zarr", "output.zarr",
              output_var="SKY", num_freq=8, pixel_stepping=4)

# Convert raw MdV beam
mdv_to_xradio("mdv-beams-L.npz", "output.zarr",
              jones="HH", part="real", antenna=-1)

Project details


Download files

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

Source Distribution

suricat_beams-0.2.2.post1.tar.gz (26.3 kB view details)

Uploaded Source

Built Distribution

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

suricat_beams-0.2.2.post1-py3-none-any.whl (31.7 kB view details)

Uploaded Python 3

File details

Details for the file suricat_beams-0.2.2.post1.tar.gz.

File metadata

  • Download URL: suricat_beams-0.2.2.post1.tar.gz
  • Upload date:
  • Size: 26.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1013-azure

File hashes

Hashes for suricat_beams-0.2.2.post1.tar.gz
Algorithm Hash digest
SHA256 860c27456ac4d2d8c60c251550d3d6c35a5ab84afb669eb10e94fd5352293689
MD5 8135acb5c91c9376c6efa42616947fd2
BLAKE2b-256 9aab28eac55dd64084d4b749ff487874118d8e57779927e4bd08f258960c62eb

See more details on using hashes here.

File details

Details for the file suricat_beams-0.2.2.post1-py3-none-any.whl.

File metadata

  • Download URL: suricat_beams-0.2.2.post1-py3-none-any.whl
  • Upload date:
  • Size: 31.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1013-azure

File hashes

Hashes for suricat_beams-0.2.2.post1-py3-none-any.whl
Algorithm Hash digest
SHA256 fa29df6b3f942eb4012e648cd6355fffa1893ab04638178886c8060a7b53fb7e
MD5 0d12e1d958f6fa37b221a5313cab8bd1
BLAKE2b-256 b31f132bc7e58cdb1b0e4b80637693fdeeca3dfe6ba3a75b4ff14dfaeb061fb7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page