Reference/API

astroplan Package

astroplan is an open source (BSD licensed) observation planning package for astronomers that can help you plan for everything but the clouds.

It is an in-development Astropy affiliated package that seeks to make your life as an observational astronomer a little less infuriating.

Functions

download_IERS_A([show_progress])

Download and cache the IERS Bulletin A table.

is_always_observable(constraints, observer, ...)

A function to determine whether targets are always observable throughout time_range given constraints in the constraints_list for a particular observer.

is_event_observable(constraints, observer, ...)

Determines if the target is observable at each time in times, given constraints in constraints for a particular observer.

is_observable(constraints, observer, targets)

Determines if the targets are observable during time_range given constraints in constraints_list for a particular observer.

max_best_rescale(vals, min_val, max_val[, ...])

rescales an input array vals to be a score (between zero and one), where the max_val goes to one, and the min_val goes to zero.

min_best_rescale(vals, min_val, max_val[, ...])

rescales an input array vals to be a score (between zero and one), where the min_val goes to one, and the max_val goes to zero.

months_observable(constraints, observer, targets)

Determines which month the specified targets are observable for a specific observer, given the supplied constriants.

moon_illumination(time[, ephemeris])

Calculate fraction of the moon illuminated.

moon_phase_angle(time[, ephemeris])

Calculate lunar orbital phase in radians.

observability_table(constraints, observer, ...)

Creates a table with information about observability for all the targets over the requested time_range, given the constraints in constraints_list for observer.

stride_array(arr, window_width)

Computes all possible sequential subarrays of arr with length = window_width

test([package, test_path, args, plugins, ...])

Run the tests using py.test.

time_grid_from_range(time_range[, ...])

Get linearly-spaced sequence of times.

Classes

AirmassConstraint([max, min, boolean_constraint])

Constrain the airmass of a target.

AltitudeConstraint([min, max, ...])

Constrain the altitude of the target.

AstroplanWarning

Superclass for warnings used by astroplan

AtNightConstraint([max_solar_altitude, ...])

Constrain the Sun to be below horizon.

Constraint()

Abstract class for objects defining observational constraints.

EclipsingSystem(primary_eclipse_time, ...[, ...])

Define parameters for an eclipsing system; useful for an eclipsing binary or transiting exoplanet.

FixedTarget(coord[, name])

Coordinates and metadata for an object that is "fixed" with respect to the celestial sphere.

GalacticLatitudeConstraint([min, max])

Constrain the distance between the Galactic plane and some targets.

LocalTimeConstraint([min, max])

Constrain the observable hours.

MoonIlluminationConstraint([min, max, ephemeris])

Constrain the fractional illumination of the Earth's moon.

MoonSeparationConstraint([min, max, ephemeris])

Constrain the distance between the Earth's moon and some targets.

NonFixedTarget([name, ra, dec, marker])

Placeholder for future function.

Observer([location, timezone, name, ...])

A container class for information about an observer's location and environment.

ObservingBlock(target, duration, priority[, ...])

An observation to be scheduled, consisting of a target and associated constraints on observations.

OldEarthOrientationDataWarning

Using old Earth rotation data from IERS

PeriodicEvent(epoch, period[, duration, name])

A periodic event defined by an epoch and period.

PhaseConstraint(periodic_event[, min, max])

Constrain observations to times in some range of phases for a periodic event (e.g.~transiting exoplanets, eclipsing binaries).

PlotBelowHorizonWarning

Warning for when something is hidden on a plot because it's below the horizon

PlotWarning

Warnings dealing with the plotting aspects of astroplan

PrimaryEclipseConstraint(eclipsing_system)

Constrain observations to times during primary eclipse.

PriorityScheduler(*args, **kwargs)

A scheduler that optimizes a prioritized list.

Schedule(start_time, end_time[, constraints])

An object that represents a schedule, consisting of a list of Slot objects.

Scheduler(constraints, observer[, ...])

Schedule a set of ObservingBlock objects

Scorer(blocks, observer, schedule[, ...])

Returns scores and score arrays from the evaluation of constraints on observing blocks

SecondaryEclipseConstraint(eclipsing_system)

Constrain observations to times during secondary eclipse.

SequentialScheduler(*args, **kwargs)

A scheduler that does "stupid simple sequential scheduling".

Slot(start_time, end_time)

A time slot consisting of a start and end time

SunSeparationConstraint([min, max])

Constrain the distance between the Sun and some targets.

Target([name, ra, dec, marker])

Abstract base class for target objects.

TargetAlwaysUpWarning

Target is circumpolar

TargetNeverUpWarning

Target never rises above horizon

TimeConstraint([min, max])

Constrain the observing time to be within certain time limits.

TransitionBlock(components[, start_time])

Parameterizes the "dead time", e.g.

Transitioner([slew_rate, ...])

A class that defines how to compute transition times from one block to another.

Class Inheritance Diagram

digraph inheritance2c68e5bcb2 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "AirmassConstraint" [URL="../api/astroplan.AirmassConstraint.html#astroplan.AirmassConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the airmass of a target."]; "AltitudeConstraint" -> "AirmassConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "AltitudeConstraint" [URL="../api/astroplan.AltitudeConstraint.html#astroplan.AltitudeConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the altitude of the target."]; "Constraint" -> "AltitudeConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "AstroplanWarning" [URL="../api/astroplan.AstroplanWarning.html#astroplan.AstroplanWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Superclass for warnings used by astroplan"]; "AstropyWarning" -> "AstroplanWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "AstropyWarning" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="The base warning class from which all Astropy warnings should inherit."]; "AtNightConstraint" [URL="../api/astroplan.AtNightConstraint.html#astroplan.AtNightConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the Sun to be below ``horizon``."]; "Constraint" -> "AtNightConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Constraint" [URL="../api/astroplan.Constraint.html#astroplan.Constraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Abstract class for objects defining observational constraints."]; "EclipsingSystem" [URL="../api/astroplan.EclipsingSystem.html#astroplan.EclipsingSystem",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Define parameters for an eclipsing system; useful for an eclipsing binary or"]; "PeriodicEvent" -> "EclipsingSystem" [arrowsize=0.5,style="setlinewidth(0.5)"]; "FixedTarget" [URL="../api/astroplan.FixedTarget.html#astroplan.FixedTarget",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Coordinates and metadata for an object that is \"fixed\" with respect to the"]; "Target" -> "FixedTarget" [arrowsize=0.5,style="setlinewidth(0.5)"]; "GalacticLatitudeConstraint" [URL="../api/astroplan.GalacticLatitudeConstraint.html#astroplan.GalacticLatitudeConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the distance between the Galactic plane and some targets."]; "Constraint" -> "GalacticLatitudeConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "LocalTimeConstraint" [URL="../api/astroplan.LocalTimeConstraint.html#astroplan.LocalTimeConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the observable hours."]; "Constraint" -> "LocalTimeConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "MoonIlluminationConstraint" [URL="../api/astroplan.MoonIlluminationConstraint.html#astroplan.MoonIlluminationConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the fractional illumination of the Earth's moon."]; "Constraint" -> "MoonIlluminationConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "MoonSeparationConstraint" [URL="../api/astroplan.MoonSeparationConstraint.html#astroplan.MoonSeparationConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the distance between the Earth's moon and some targets."]; "Constraint" -> "MoonSeparationConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "NonFixedTarget" [URL="../api/astroplan.NonFixedTarget.html#astroplan.NonFixedTarget",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Placeholder for future function."]; "Target" -> "NonFixedTarget" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Observer" [URL="../api/astroplan.Observer.html#astroplan.Observer",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A container class for information about an observer's location and"]; "ObservingBlock" [URL="../api/astroplan.ObservingBlock.html#astroplan.ObservingBlock",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="An observation to be scheduled, consisting of a target and associated"]; "OldEarthOrientationDataWarning" [URL="../api/astroplan.OldEarthOrientationDataWarning.html#astroplan.OldEarthOrientationDataWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Using old Earth rotation data from IERS"]; "AstroplanWarning" -> "OldEarthOrientationDataWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "PeriodicEvent" [URL="../api/astroplan.PeriodicEvent.html#astroplan.PeriodicEvent",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A periodic event defined by an epoch and period."]; "PhaseConstraint" [URL="../api/astroplan.PhaseConstraint.html#astroplan.PhaseConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain observations to times in some range of phases for a periodic event"]; "Constraint" -> "PhaseConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "PlotBelowHorizonWarning" [URL="../api/astroplan.PlotBelowHorizonWarning.html#astroplan.PlotBelowHorizonWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Warning for when something is hidden on a plot because it's below the horizon"]; "PlotWarning" -> "PlotBelowHorizonWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "PlotWarning" [URL="../api/astroplan.PlotWarning.html#astroplan.PlotWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Warnings dealing with the plotting aspects of astroplan"]; "AstroplanWarning" -> "PlotWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "PrimaryEclipseConstraint" [URL="../api/astroplan.PrimaryEclipseConstraint.html#astroplan.PrimaryEclipseConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain observations to times during primary eclipse."]; "Constraint" -> "PrimaryEclipseConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "PriorityScheduler" [URL="../api/astroplan.PriorityScheduler.html#astroplan.PriorityScheduler",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A scheduler that optimizes a prioritized list. That is, it"]; "Scheduler" -> "PriorityScheduler" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Schedule" [URL="../api/astroplan.Schedule.html#astroplan.Schedule",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="An object that represents a schedule, consisting of a list of"]; "Scheduler" [URL="../api/astroplan.Scheduler.html#astroplan.Scheduler",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Schedule a set of `~astroplan.scheduling.ObservingBlock` objects"]; "Scorer" [URL="../api/astroplan.Scorer.html#astroplan.Scorer",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Returns scores and score arrays from the evaluation of constraints on"]; "SecondaryEclipseConstraint" [URL="../api/astroplan.SecondaryEclipseConstraint.html#astroplan.SecondaryEclipseConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain observations to times during secondary eclipse."]; "Constraint" -> "SecondaryEclipseConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "SequentialScheduler" [URL="../api/astroplan.SequentialScheduler.html#astroplan.SequentialScheduler",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A scheduler that does \"stupid simple sequential scheduling\". That is, it"]; "Scheduler" -> "SequentialScheduler" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Slot" [URL="../api/astroplan.Slot.html#astroplan.Slot",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A time slot consisting of a start and end time"]; "SunSeparationConstraint" [URL="../api/astroplan.SunSeparationConstraint.html#astroplan.SunSeparationConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the distance between the Sun and some targets."]; "Constraint" -> "SunSeparationConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Target" [URL="../api/astroplan.Target.html#astroplan.Target",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Abstract base class for target objects."]; "TargetAlwaysUpWarning" [URL="../api/astroplan.TargetAlwaysUpWarning.html#astroplan.TargetAlwaysUpWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Target is circumpolar"]; "AstroplanWarning" -> "TargetAlwaysUpWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "TargetNeverUpWarning" [URL="../api/astroplan.TargetNeverUpWarning.html#astroplan.TargetNeverUpWarning",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Target never rises above horizon"]; "AstroplanWarning" -> "TargetNeverUpWarning" [arrowsize=0.5,style="setlinewidth(0.5)"]; "TimeConstraint" [URL="../api/astroplan.TimeConstraint.html#astroplan.TimeConstraint",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Constrain the observing time to be within certain time limits."]; "Constraint" -> "TimeConstraint" [arrowsize=0.5,style="setlinewidth(0.5)"]; "TransitionBlock" [URL="../api/astroplan.TransitionBlock.html#astroplan.TransitionBlock",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Parameterizes the \"dead time\", e.g. between observations, while the"]; "Transitioner" [URL="../api/astroplan.Transitioner.html#astroplan.Transitioner",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="A class that defines how to compute transition times from one block to"]; }

astroplan.plots Package

astroplan.plots contains functions for making plots of commonly-used quantities in observation planning (e.g., airmass vs. time), using astroplan and Matplotlib.

Functions

plot_airmass(targets, observer, time[, ax, ...])

Plots airmass as a function of time for a given target.

plot_altitude(targets, observer, time[, ax, ...])

Plots altitude as a function of time for a given target.

plot_finder_image(target[, survey, ...])

Plot survey image centered on target.

plot_parallactic(target, observer, time[, ...])

Plots parallactic angle as a function of time for a given target.

plot_schedule_airmass(schedule[, show_night])

Plots when observations of targets are scheduled to occur superimposed upon plots of the airmasses of the targets.

plot_sky(target, observer, time[, ax, ...])

Plots target positions in the sky with respect to the observer's location.

plot_sky_24hr(target, observer, time[, ...])

Plots target positions in the sky with respect to the observer's location over a twenty-four hour period centered on time.