Package: applefy
Applefy: Robust Detection Limits for High-Contrast ImagingThis is the documentation ofapplefy, a Python package for calculating
detection limits for exoplanet high contrast imaging (HCI) datasets.applefyprovides a number of features and functionalities to improve the accuracy
and robustness of contrast curve calculations. It implements the classical
approach based on the t-test (compareMawet et al. 2014) as well as the parametric
boostrap test for non-Gaussian residual noise (Bonse et al. 2023).Applefy has two main features:Compute contrast curves (seedocumentation)Compute contrast grids (seedocumentation)Further, this repository contains the code needed to reproduce the results of
our paper, availablehere.DocumentationA full documentation of the package, including several examples and tutorials
can be foundon ReadTheDocs.This short guide will walk you through the required steps to set up and installapplefy.The code was written forPython 3.8 and aboveInstallationThe code ofapplefyis available on thePyPI repositoryas well as onGitHub. Westronglyrecommend you
to use avirtual environmentto install
the package.Applefy can only be used together with a data post-processing library
for high-contrast imaging data! The following packages are currently
supported:PynPointVIPInstallation from PyPIJust run:pipinstallapplefyInstallation from GitHubStart by cloning the repository and installapplefyas a Python package:gitclonegit@github.com:markusbonse/applefy.git;cdapplefy;pipinstall.In case you intend to modify the package you can install the package in
"edit mode" by using the-eflag:pipinstall-e.Additional OptionsDepending on the use caseapplefycan be installed with additional options.
If you installapplefyfrom GitHub you can add them by:pipinstall-e".[option1,option2,...]"If you installapplefyfrom PiPy you can add them by:pipinstall"applefy[option1,option2,...]"The following options are available:dev: Adds all dependencies needed to build the documentation page withsphinx.fast_sort: Installs the libraryparallel_sortwhich can speed up the
calculation ofbootstrap experiments. Since,
parallel_sort is a wrapper around the GNU library it is only supported on Linux.plotting: Installs the librariesseaborn,matplotlibandbokehwhich we use in our plots.vip: Installs applefy withVIP.
Note, this option is conflicting with the
optionpynpoint.pynpoint: Installs applefy with PynPoint using thePynPointversion available on GitHub. Note, this option is conflicting with the optionvip.
This option is only available if you installapplefyfrom GitHub.Demonstration datasetThe tutorials in theuser documentationare based
on a demonstration dataset (NACO at the VLT). The data is publicly available
atZenodo. The repository
contains three files:30_data: This is the NACO L' Beta Pic dataset as a hdf5 already.
The data was pre-processed withPynPoint.70_results: Contains results created by the tutorials of the user
documentation. They are only needed if you don't want to compute your own PCA
residuals.laplace_lookup_tables.csv: Are the lookup tables for the
LaplaceBootstrapTest.Reproduce our resultsCheck out theplot galleryin theapplefydocumentation.Authors and CitationAll code was written by Markus J. Bonse, with additional contributions from
Timothy Gebhard. Detailed information on the citation can be foundhere.