InstantaneousColorMetric

class rubin_sim.maf.metrics.InstantaneousColorMetric(n_pairs=1, snr_limit=10, n_hours=0.5, b_one='g', b_two='r', **kwargs)

Bases: BaseMoMetric

Identify SSobjects which could have observations suitable to determine colors.

Generally, this is not the mode LSST would work in - the lightcurves of the objects mean that the time interval would have to be quite short.

This is roughly defined as objects which have more than n_pairs pairs of observations with SNR greater than snr_limit, in bands bandOne and bandTwo, within n_hours.

Parameters:
n_pairs: int, optional

The number of pairs of observations (in each band) that must be within n_hours Default 1

snr_limit: float, optional

The SNR limit for the observations. Default 10.

n_hours: float, optional

The time interval between observations in the two bandpasses (hours). Default 0.5 hours.

b_one: str, optional

The first bandpass for the color. Default ‘g’.

b_two: str, optional

The second bandpass for the color. Default ‘r’.

Returns:
int

0 (no color possible under these constraints) or 1 (color possible).

Methods Summary

run(sso_obs, orb, hval)

Calculate the metric value.

Methods Documentation

run(sso_obs, orb, hval)

Calculate the metric value.

Parameters:
sso_obs: np.ndarray

The input data to the metric (same as the parent metric).

orb: np.ndarray

The information about the orbit for which the metric is being calculated.

hvalfloat

The H value for which the metric is being calculated.

Returns:
float or np.ndarray or dict