def METHOD_NAME(self, probabilities: List[Tensor] = None, indices=None):
    if probabilities is not None and indices:
        raise RuntimeError("The `probabilities` and `indices` are mutually exclusive, pass only of one them.")
    if probabilities is not None and len(probabilities) != 0:
        probabilities = torch.cat([p[0].unsqueeze(0) for p in probabilities], dim=0)
        uncertainties = self.heuristic.get_uncertainties(probabilities)
        indices = np.argsort(uncertainties)
        if self._dataset is not None:
            self._dataset.METHOD_NAME(indices[-self.query_size :])