Skip to content

Commit

Permalink
added backward compability methods
Browse files Browse the repository at this point in the history
  • Loading branch information
plison committed Mar 25, 2022
1 parent f5145c3 commit 86878ba
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions skweak/aggregation.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,12 @@ def add_label_group(self, coarse_label: str, sub_labels: Set[str]):
if label not in self.observed_labels:
self.observed_labels.append(label)

def add_underspecified_label(self, coarse_label: str, sub_labels: Set[str]):
"""Kept for backward compability purposes. The method add_label_group
should be preferred."""

self.add_label_group(coarse_label, sub_labels)


def _get_vote_matrix(self, include_underspec=True) -> Tuple[np.ndarray, np.ndarray]:
"""Creates a boolean matrice of shape (nb_observed_labels, nb_out_labels)
Expand Down

0 comments on commit 86878ba

Please sign in to comment.