Exemple #1
0
def _dummy_performance() -> Performance:
    return Performance.from_dict(
        {
            mm: np.nan
            for m in Performance.metrics()
            for mm in [f"{m}_mean", f"{m}_std"]
        }
    )
Exemple #2
0
 def inverse_transform(self,
                       X: npt.NDArray[np.float32],
                       _y: Any = None) -> List[Performance]:
     df = pd.DataFrame(X, columns=self.feature_names_).assign(
         **{
             col: np.nan
             for col in set(self.all_feature_names_) -
             set(self.feature_names_)
         })
     return [
         Performance.from_dict(row.to_dict()) for _, row in df.iterrows()
     ]