actsnclass.purity
- actsnclass.purity(label_pred: list, label_true: list, ia_flag=1)
Calculate purity.
- Parameters:
label_pred (list) – Predicted labels
label_true (list) – True labels
ia_flag (int (optional)) – Flag used to identify Ia objects. Default is 1.
- Returns:
Purity – Fraction of true SN Ia in the final classified Ia sample.
- Return type:
float