Scripts for analyzing ZTF periodic data
This package implements several period-searching algorithms. Below we explain some of them.
-
Generalized Conditional Entropy (GCE)
ztfperiodic uses code written by Michael Katz (in cuda); Algorithm paper: Graham et al. (2013)
Download:git clone https://github.com/mikekatz04/gce
Installation:python setup.py install
(you need a CUDA-capable machine.) -
Analysis Of Variance (AOV)
Code originally from this website; Algorithm paper: Schwarzenberg-Czerny (1996) and Schwarzenberg-Czerny (1989). Note thatncov
is the number of phase coverages (defualt=2, ok), andnh2
is the number of phase bins (default=3, better to increase this).
First, runsource build.sh
in the ztfperiodic/pyaov/ directory, then copy theaov.cpython-36m-darwin.so
file to lib/python3.7/site-packages/ or equivalent. -
Lomb-Scargle (LS)
-
Box-fitting Least Squares (BLS)
-
Phase Dispersion Minimization (PDM, PDM2)
Algorithm papers: Stellingwerf (1978) -
Fast Fourier Transform (FFT)
Consult this paper if you're not sure which algorithm to adopt.
Below we list several examples to run scripts in the /bin directory.
python ztfperiodic_object_followup.py --doGPU --ra your_ra --declination your_dec --doSpectra --user your_kowalski_username --pwd your_kowalski_password
If copying to schoty, copy a netrc that can talk to schoty into the current directory, otherwise touch netrc should do.
nvidia-docker build -t python-ztfperiodic . nvidia-docker run -it python-ztfperiodic
For debugging: docker run -it python-ztfperiodic
- cuda
If you seeGPUassert: all CUDA-capable devices are busy or unavailable gcex/src/manager.cu 57
, typenvidia-smi
and checkVolatile GPU-Util
. Tryexport CUDA_VISIBLE_DEVICES=1
.
Using a conda environment: conda install astropy Cython h5py matplotlib numpy pandas scipy pytables conda install -c conda-forge astropy-healpix astroquery astroplan healpy pip install penquins Install from source: https://github.com/ejaszewski/periodfind