This notebook is available at https://github.com/arjunsavel/simmer/tree/master/docs/pages/PHARO_reduction.ipynb

PHARO Reduction Quickstart

[2]:
import os

import simmer.insts as i
import simmer.drivers as drivers
from simmer.tests.tests_reduction import download_folder

1. Collect your data

For our purposes, we’ll just download some quickstart data.

[3]:
download_folder("PHARO_integration")

2. Initializing the instrument

We begin by instantiating the code — but this time, with a different instrument and different data. The downloaded files will take up about a gigabyte of space, and they’ll be placed in a folder in your current directory.

Many specifics (plate scale, FITS headers) are bound as attributes and methods to their respective instrument class.

[4]:
inst = i.PHARO()

This instantiates inst as an instrument object prepared to reduced ShARCS data.

3. Creating the config file

Next, you’ll want to set up your config file path, raw data directory, and reduced data directory. In our case, this takes the form of the below. Note that reddir needs to be a directory that’s already been created.

[5]:
path_to_notebook = os.getcwd()

config_file = "test_image_config.csv"
raw_dir = "PHARO_integration/"

os.mkdir("reduced")

reddir = "reduced/"

4. Performing the reduction

Finally, run all drivers to perform the reduction!

[ ]:
drivers.all_driver(inst, config_file, raw_dir, reddir)
Running darks: 100%|██████████| 1/1 [00:06<00:00,  6.40s/it]
Running flats: 100%|██████████| 1/1 [00:05<00:00,  5.96s/it]
Running skies: 100%|██████████| 1/1 [00:10<00:00, 10.27s/it]
Running image driver: 100%|██████████| 1/1 [01:31<00:00, 91.79s/it]
Running registration:   0%|          | 0/1 [00:00<?, ?it/s]
[ ]: