constrain_pd

hybrid_learning.experimentation.exp_eval_common.constrain_pd(df, constraints)[source]

Given a dict of {col_name: constraint_value} return the dataframe row subset fulfilling all constraints.

Parameters
  • df (DataFrame) –

  • constraints (Dict[str, Any]) –