sherlockpipe.search.sherlock.Sherlock
- class sherlockpipe.search.sherlock.Sherlock(sherlock_targets: List[SherlockTarget], explore: bool = False, update_ois: bool = False, update_force: bool = False, update_clean: bool = False, cache_dir: str = '/home/docs/', results_dir: str = None)
Bases:
objectMain SHERLOCK PIPEline class to be used for loading input, setting up the running parameters and launch the analysis of the desired TESS, Kepler, K2 or csv objects light curves.
- __init__(sherlock_targets: List[SherlockTarget], explore: bool = False, update_ois: bool = False, update_force: bool = False, update_clean: bool = False, cache_dir: str = '/home/docs/', results_dir: str = None)
Initializes a Sherlock object, loading the OIs from the csvs, setting up the detrend and transit configurations, storing the provided object_infos list and initializing the builders to be used to prepare the light curves for the provided object_infos.
- Parameters:
update_ois (bool) – Flag to signal SHERLOCK for updating the TOIs, KOIs and EPICs
sherlock_targets (List[SherlockTarget]) – a list of objects information to be analysed
explore (bool) – whether to only run the prepare stage for all objects
update_ois – whether ois files should be updated
update_force (bool) – whether a complete update of metadata should be done
update_clean (bool) – whether current metadata should be wiped-out before update
cache_dir (str) – directory to store caches for sherlock.
results_dir (str) – directory to store results
Methods
__init__(sherlock_targets[, explore, ...])Initializes a Sherlock object, loading the OIs from the csvs, setting up the detrend and transit configurations, storing the provided object_infos list and initializing the builders to be used to prepare the light curves for the provided object_infos.
Filters the in-memory OIs given some basic filters associated to big and long-period targets.
Filters the in-memory OIs given some basic filters associated to hot jupiters properties.
Filters the in-memory OIs given some basic filters associated to multiplanet targets.
filter_ois(function)Applies a function accepting the Sherlock objects of interests dataframe and stores the result into the Sherlock same ois dataframe.
Filters the in-memory OIs given some basic filters associated to big and long-period targets.
limit_ois([offset, limit])Limits the in-memory loaded OIs given an offset and a limit (like a pagination)
load_ois(refresh_ois, refresh_force, ...)Loads the csv OIs files into memory
noise(time, flux, signal_power)Downloads the TOIs, KOIs and EPIC OIs into csv files.
run([all_targets_properties])Entrypoint of Sherlock which launches the main execution for all the input object_infos
run_multiprocessing(n_processors, func, ...)setup_files(refresh_ois, refresh_force, ...)Loads the objects of interest data from the downloaded CSVs.
Attributes
MASK_MODESNUMBERS_REGEXNUM_CORESOBJECT_ID_REGEXRESULTS_DIRVALID_DETREND_METHODSVALID_PERIODIC_DETREND_METHODSconfig_stepoisreportrun_oistime_reportstransits_min_countuse_oiswl_maxwl_min- filter_high_snr_long_period_ois()
Filters the in-memory OIs given some basic filters associated to big and long-period targets. This method is added as an example
- Returns:
the Sherlock object itself
- filter_hj_ois()
Filters the in-memory OIs given some basic filters associated to hot jupiters properties. This method is added as an example
- Returns:
the Sherlock object itself
- filter_multiplanet_ois()
Filters the in-memory OIs given some basic filters associated to multiplanet targets. This method is added as an example
- Returns:
the Sherlock object itself
- filter_ois(function)
Applies a function accepting the Sherlock objects of interests dataframe and stores the result into the Sherlock same ois dataframe.
- Parameters:
function – the function to be applied to filter the Sherlock OIs.
- Returns:
the Sherlock object itself
- filter_short_period_ois()
Filters the in-memory OIs given some basic filters associated to big and long-period targets. This method is added as an example
- Returns:
the Sherlock object itself
- limit_ois(offset=0, limit=0)
Limits the in-memory loaded OIs given an offset and a limit (like a pagination)
- Parameters:
offset – the position where the subset must start
limit – maximum number of ois to be returned
- Returns:
the Sherlock object itself
- load_ois(refresh_ois, refresh_force, refresh_clean)
Loads the csv OIs files into memory
- Returns:
the Sherlock object itself
- refresh_ois()
Downloads the TOIs, KOIs and EPIC OIs into csv files.
- Returns:
the Sherlock object itself
- run(all_targets_properties: dict = None)
Entrypoint of Sherlock which launches the main execution for all the input object_infos
- setup_files(refresh_ois, refresh_force, refresh_clean, results_dir=None)
Loads the objects of interest data from the downloaded CSVs.
- Parameters:
refresh_ois – Flag update the TOIs, KOIs and EPICs
results_dir – Stores the directory to be used for the execution.
- Returns:
the Sherlock object itself