Skip to main content
`Ctrl`+`K`

# Scorer

class astroplan.Scorer(blocks, observer, schedule, global_constraints=[])

  Bases: `object`

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

  Parameters:
    blocks list of `ObservingBlock` objects

      list of blocks that need to be scored

    observer `Observer`

      the observer

    schedule `Schedule`

      The schedule inside which the blocks should fit

    global_constraints list of `Constraint` objects

      any `Constraint` that applies to all the blocks

  Methods Summary

  `create_score_array`([time_resolution]) | this makes a score array over the entire schedule for all of the blocks and each `Constraint` in the .constraints of each block and in self.global_constraints.
  `from_start_end`(blocks, observer, start_time, ...) | for if you don't have a schedule/ aren't inside a scheduler

  Methods Documentation

  create_score_array(time_resolution=<Quantity 1. min>)

    this makes a score array over the entire schedule for all of the blocks and each `Constraint` in the .constraints of each block and in self.global_constraints.

    Parameters:
      time_resolution `Quantity`

        the time between each scored time

    Returns:
      score_array `ndarray`

        array with dimensions (# of blocks, schedule length/ `time_resolution`

  classmethod from_start_end(blocks, observer, start_time, end_time, global_constraints=[])

    for if you don’t have a schedule/ aren’t inside a scheduler