{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# The Instrument object\n", "\n", "The `Instrument` class within galfind is an abstract base class containing references to both the `Facility` class that it is a part of and the names of the filters which it uses for photometric imaging. It is parent to 4 Singleton child classes which, in order of increasing wavelength coverage, are: `ACS_WFC`, `WFC3_IR`, `NIRCam`, `MIRI`. The `Facility` class is also an abstract base class parent to 2 Singleton classes, namely `HST` (`ACS_WFC` and `WFC3_IR`) and `JWST` (`NIRCam` and `MIRI`). These base class names are chosen to follow the convention used in the SVO.\n", "\n", "There are, of course, more potential optical or NIR facility/instrument combinations that the user may wish to include in their analysis that are excluded from the 4 above but included in the SVO database. These are, most notably, Spitzer/IRAC, JWST/NIRISS, HST/WFC3_UVIS, HST/NICMOS, and any ground based cameras such as Subaru/HSC or CFHT/MegaCam. There is no particular limitation preventing us from including these other than merely available time, and any contributions to galfind regarding this would be gladly accepted (follow [this link](../getting_started/updates.rst) for more information regarding this). It is worth baring in mind that the most major time consumption here is the handling of `PSF` modelling and subsequent aperture corrections, which we will get onto in both this notebook and [the next](PSF.ipynb).\n", "\n", "## Example 1: Singleton objects\n", "\n", "To start off, we need to first instantiate a Singleton object. For this example, we shall arbitrarily choose `NIRCam`. There is nothing particularly fancy going on here since this is a singleton object. Once we instantiate one instance of NIRCam, any further instances match it.\n", "\n", "" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [ { "ename": "", "evalue": "", "output_type": "error", "traceback": [ "\u001b[1;31mFailed to start the Kernel. \n", "\u001b[1;31mUnhandled error. \n", "\u001b[1;31mView Jupyter log for further details." ] } ], "source": [ "from galfind import NIRCam\n", "\n", "# Create a NIRCam object\n", "nircam = NIRCam()\n", "\n", "# Print the NIRCam object\n", "print(nircam)\n", "\n", "# Add random attributes to the NIRCam object\n", "nircam.random_attribute = 42\n", "nircam.whos_a_good_singleton = \"I am!\"\n", "\n", "# Create another NIRCam object to showcase the Singleton\n", "nircam2 = NIRCam()\n", "print(nircam2)\n", "\n", "# Delete the second NIRCam object (also deletes the first)\n", "del nircam2" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 2: Making model NIRCam PSFs with WebbPSF" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3: Making empirical PSFs for NIRCam from the JOF imaging" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 4: Comparing model and empirical PSFs" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 5: Calculating aperture corrections from the PSFs" ] } ], "metadata": { "kernelspec": { "display_name": "more_and_more_galfind", "language": "python", "name": "python3" }, "language_info": { "name": "python", "version": "3.9.20" } }, "nbformat": 4, "nbformat_minor": 2 }