pyetc: A New Exposure Time Calculator for Hubble

Rosa Diaz, rdiaz@stsci.edu

The Institute has recently developed a new exposure time calculator (ETC)—pyetc, a web-based application that calculates either the exposure time needed to achieve a certain signal-to-noise ratio (SNR), or the SNR that would be achieved by a certain exposure time. Users need such calculations to explore the parameter spaces of instruments and detectors, to prepare realistic proposals, and to plan optimal observations following proposal selection.

Achieving the 10% accuracy goal of pyetc requires good models of many types of astronomical targets and environments. It also demands accurate, up-to-date information about the telescope and instruments. To achieve this, the instrument teams at the Institute monitor the observatory closely, constantly gather new calibration data, and improve the fidelity of the calibrations. The new system’s design allows quick changes to the computational engine and instrument data. It supports many instruments with common code. In operation, it balances loads and handles failure and handover to backup systems during times of heavy usage. This robust design and ongoing maintenance ensures that the ETC promptly makes any significant variation in the response of an instrument available to users.

pyetc features

pyetc has the capability to support multiple ETC versions on the same computer, and provides one-step installation. These features provide the ability to make changes, validate them, and provide them to users in short order.

pyetc offers a simpler codebase, which can be adapted to other instruments and missions, like Webb, for example. Although previous versions of the ETC were technically capable of such adaptation, they demanded significant resources to make the necessary changes. The new tool makes it easy.

pyetc makes testing easier and more effective.  Verifying the accuracy and correctness of any changes to a Hubble ETC can be daunting, due to the large number of input parameters and observing modes. pyetc uses a test interface with a consistent test scheme. Also, pyetc expands test coverage to a wider parameter space, and provides end-to-end testing of the system. These features allow us to identify and eliminate many problems before users encounter them.

pyetc separates computational and web functionality. All ETC calculations are contained within one part of the system, while the web framework (which uses Django) processes the information to and from the user. In the future, this separation will allow users with only a personal computer to run pyetc calculations using Python scripting, and to write Python scripts that directly use the calculation engine, for both batch processing and science exploration.

The instrumental information and other data used by pyetc to perform its calculations are, unlike older versions, independent of the software. These data are now stored in the calibration database system (CDBS), which will be accessible to the instrument teams for updating, validating, and testing. It will also be available to users who want to know the details of their calculations, or who wish to run batch pyetc calculations. Furthermore, following CDBS standards, these files will be under version control and strict protocols to ensure the quality of the data.