Skip to main content

Physical optics (PSFs and diffraction) for the HWO direct imaging simulation suite

Project description

physicaloptix

Physical optics — PSFs and diffraction — for the HWO direct-imaging simulation suite.

What physicaloptix is

physicaloptix turns an optixstuff hardware description into point-spread functions by wave-optics propagation, using dLux as the (hidden, swappable) backend. It is a downstream consumer of optixstuff — parallel to coronagraphoto (2D image simulation) and jaxEDITH (exposure-time and yield calculations) — so optixstuff itself stays free of diffraction code.

The key piece is DLuxCoronagraph, which implements optixstuff's AbstractCoronagraph. Build one from an optixstuff primary and hand it to any downstream tool: it is consumed as an AbstractCoronagraph, so coronagraphoto and jaxEDITH get dLux-propagated PSFs by dependency injection, without depending on physicaloptix or dLux themselves.

import physicaloptix as po

coro = po.DLuxCoronagraph.from_primary(primary)      # optixstuff in, dLux hidden
psf = coro.on_axis_psf(600.0, pixel_scale_rad, npix)  # PSF out

What physicaloptix is not

  • Not a hardware model. The telescope / coronagraph / detector description lives in optixstuff; physicaloptix consumes it.
  • Not a PSF interpolator. That's yippy's job (a sampled YIP table). physicaloptix is its functional sibling — live propagation — and both back the same AbstractCoronagraph slot.
  • Not a scene model. Stars, planets, disks, and zodi live in skyscapes.

Architecture

Built on JAX, Equinox, and dLux, physicaloptix provides:

  • The optixstuff -> dLux adapterto_dlux_aperture, a singledispatch that renders each optixstuff primary type into a dLux aperture (segmented hex -> MultiAperture, simple circular -> CircularAperture).
  • A dLux-backed coronagraphDLuxCoronagraph, an optixstuff AbstractCoronagraph producing on_axis_psf / off_axis_psf by propagation.
  • A facadepsf(primary, ...), a one-liner from primary to PSF.

Ecosystem position

flowchart TB
    optix["<b>optixstuff</b><br/>Telescope · Coronagraph · Detector · OpticalPath"]
    physopt["<b>physicaloptix</b><br/>dLux-backed PSFs / diffraction<br/>DLuxCoronagraph"]
    yippy["<b>yippy</b><br/>Sampled-YIP PSF interpolation"]
    corono["<b>coronagraphoto</b><br/>2D image simulation"]
    jaxedith["<b>jaxEDITH</b><br/>Exposure-time / yield"]

    optix --> physopt
    optix --> yippy
    physopt -- AbstractCoronagraph --> corono
    physopt -- AbstractCoronagraph --> jaxedith
    yippy -- AbstractCoronagraph --> corono

Installation

pip install physicaloptix

Status

This package is in early development (pre-v0.1.0). No coronagraph mask (focal-plane / Lyot) is modelled yet, so on_axis_psf is currently the telescope PSF.

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

physicaloptix-0.0.1.tar.gz (8.9 kB view details)

Uploaded Source

Built Distribution

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

physicaloptix-0.0.1-py3-none-any.whl (7.8 kB view details)

Uploaded Python 3

File details

Details for the file physicaloptix-0.0.1.tar.gz.

File metadata

  • Download URL: physicaloptix-0.0.1.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for physicaloptix-0.0.1.tar.gz
Algorithm Hash digest
SHA256 2e65385dbf1157f2fc8f207a1024eee4ffa2365f4a4a3b7f37e28be4e1083220
MD5 656a38579c960f6a9d7c79fb2c39f79f
BLAKE2b-256 6eb4bbec436dc65db8b96664a89e6671d34a782d659b050ac417cde33cf396a8

See more details on using hashes here.

Provenance

The following attestation bundles were made for physicaloptix-0.0.1.tar.gz:

Publisher: publish-to-pypi.yml on CoreySpohn/physicaloptix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file physicaloptix-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: physicaloptix-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 7.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for physicaloptix-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c1551032ee7a99da6c91cf9a9c61db4f7a9ffa0b78a84678bb46b999615e497d
MD5 bb58fae6f461d917aac5ab2c125eaa88
BLAKE2b-256 a9466439014ee8cc80b79d5dde3c880824fc63802461a14b85a57e0f2a12697e

See more details on using hashes here.

Provenance

The following attestation bundles were made for physicaloptix-0.0.1-py3-none-any.whl:

Publisher: publish-to-pypi.yml on CoreySpohn/physicaloptix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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