{ "cells": [ { "cell_type": "markdown", "id": "19dd933a-a9d8-4416-9ae3-220e2f4ea63c", "metadata": {}, "source": [ "# Transitioning from WebbPSF to STPSF" ] }, { "attachments": {}, "cell_type": "markdown", "id": "5b3eae88-ddcb-4d90-8dba-7aa2abd36f9a", "metadata": {}, "source": [ "To reflect its broader support for Roman as well as James Webb, WebbPSF functionality has now migrated to STPSF (Space Telescope PSF). STPSF functionality is currently the same as WebbPSF, only the name is different. \n", "\n", "For users who have not switched to using STPSF:\n", "WebbPSF is now an alias of STPSF and is running code from the STPSF library. Therefore, the versioning of WebbPSF will not be parallel to the released versions of STPSF. WebbPSF will automatically include the newest STPSF changes.\n", "\n", "For users ready to switch to STPSF:\n", "If you are ready to make the change to STPSF, this notebook will help you explore the best options in order to transition your WebbPSF scripts and codes into STPSF. Generally speaking there are two options:\n", "\n", "- `import stpsf`. This is the preferred method. In this case you will fully transition to the STPSF usage, thus, you need to replace all the WebbPSF calls to STPSF.\n", "\n", "- `import stpsf as webbpsf`. This can be done at the beginning of your code and it will keep your code as-is, preserving WebbPSF syntax to function calls. This is beneficial if you just want to do a quick change to your codebase. However, a full rename (as outlined below), will lead to a more legible and healthy codebase.\n", "\n", "\n", "\n", "Note that in both cases you'll be required to install STPSF, including downloading the STPSF data files and setting a STPSF_PATH environment variable. See instructions under [Requirements & Installation](https://stpsf.readthedocs.io/en/latest/installation.html#requirements-installation). \n", "WebbPSF is no longer a requirement and can be removed from your environment. Any references to WebbPSF in your library via requirements.txt or pyproject.toml, should be replaced with STPSF.\n", "\n", "