is_labeled#
- skactiveml.utils.is_labeled(y, missing_label=nan, *, target_type='single-output')[source]#
Creates a boolean mask indicating present labels.
- Parameters:
- yarray-like of shape (n_samples,) or (n_samples, n_outputs)
Class labels to be checked w.r.t. to present labels.
- missing_labelnumber or str or None or np.nan, default=np.nan
Value to represent a missing label.
- target_type“single-output” or “multi-label”, default=”single-output”
The resolved target type. For multi-label targets, y must be two-dimensional. Furthermore, a row y[i] must contain either only observed labels or only missing_label values, i.e., no mixing within a row.
- Returns:
- is_lbldnp.ndarray of shape (n_samples,) or (n_samples, n_outputs)
Boolean mask indicating present labels in y.
If target_type=”single-output”, is_lbld has the same shape as y.
If target_type=”multi-label”, is_lbld has shape (n_samples,).
Examples using skactiveml.utils.is_labeled#
Regression based Kullback Leibler Divergence Maximization
Regression Tree Based Active Learning (RT-AL) with Diversity Selection
Regression Tree Based Active Learning (RT-AL) with Random Selection
Regression Tree Based Active Learning (RT-AL) with Representativity Selection