survey.snls#
This module defines the SNLS survey class, including the SNLS field coordinates, MegaCam footprint, and tools to load the observing logs.
- skysurvey.survey.snls.get_snls_field_coordinates(fieldid_name='fieldid')[source]#
Get the radec location of the 4 SNLS fields.
- Parameters:
fieldid_name (str) – name of the fieldid column.
- Return type:
pandas.DataFrame
- skysurvey.survey.snls.get_snls_footprint()[source]#
Returns a 1-degree side square footprint.
- Return type:
shapely.geometry.Polygon
- skysurvey.survey.snls.get_weblogs(url='https://supernovae.in2p3.fr/snls5/snls_obslogs.csv')[source]#
Load and parse data from the input url.
- Parameters:
url (str) – url to the data.
- Return type:
pandas.DataFrame
- skysurvey.survey.snls.register_snls_bandpasses(filters=['g', 'r', 'i', 'z', 'y'], prefix='megacampsf', at_radius=13.0)[source]#
Register snls band passes to sncosmo assuming a single radius.
- class skysurvey.survey.snls.SNLS(data=None, **kwargs)[source]#
Bases:
GridSurveyA class to model the SNLS survey.
- Parameters:
data (pandas.DataFrame) – observing data.
**kwargs – goes to
GridSurvey.__init__
- classmethod from_logs(logpath=None, **kwargs)[source]#
Loads the data from the observing logs.
If None provided, this uses: https://supernovae.in2p3.fr/snls5/snls_obslogs.csv
- Parameters:
logpath (path) – filepath to where the logs are stored (as csv). If None, the official snls webpage is used: https://supernovae.in2p3.fr/snls5/snls_obslogs.csv
GridSurvey.__init__ (**kwargs goes to)
- Return type:
instance
- classmethod from_pointings(data, **kwargs)[source]#
Loads from observing log data.
- Parameters:
data (pandas.DataFrame, dict) – observing logs, must contains: [‘zp’, ‘fieldid’, ‘gain’, ‘skynoise’, ‘mjd’, ‘band’]
GridSurvey.__init__ (**kwargs goes to)
- Returns:
instance
See also
———
:func:`from_logs()` (loads the data from input file (or web).)