apply_models

lstchain.reco.dl1_to_dl2.apply_models(dl1, classifier, reg_energy, reg_disp_vector=None, reg_disp_norm=None, cls_disp_sign=None, effective_focal_length=<Quantity 29.30565 m>, custom_config=None)

Apply previously trained Random Forests to a set of data depending on a set of features. The right set of disp models must be passed depending on the config.

Parameters:
dl1: `pandas.DataFrame`
classifier: string | Path | bytes | sklearn.ensemble.RandomForestClassifier

Path to the random forest filename or file or pre-loaded RandomForestClassifier object for Gamma/Hadron separation

reg_energy: string | Path | bytes | sklearn.ensemble.RandomForestRegressor

Path to the random forest filename or file or pre-loaded RandomForestRegressor object for Energy reconstruction

reg_disp_vector: string | Path | bytes | sklearn.ensemble.RandomForestRegressor

Path to the random forest filename or file or pre-loaded RandomForestRegressor object for disp vector reconstruction

reg_disp_norm: string | Path | bytes | sklearn.ensemble.RandomForestRegressor

Path to the random forest filename or file or pre-loaded RandomForestRegressor object for disp norm reconstruction

cls_disp_sign: string | Path | bytes | sklearn.ensemble.RandomForestClassifier

Path to the random forest filename or file or pre-loaded RandomForestClassifier object for disp sign reconstruction

effective_focal_length: `astropy.unit`
custom_config: dictionary

Modified configuration to update the standard one

Returns:
pandas.DataFrame

dataframe including reconstructed dl2 features