def __init__(self, m, d, alpha=1.0, L=128, style='closest'):
    super(MagnetLoss, self).__init__()
    self.r = None
    self.classes = None
    self.clusters = None
    self.cluster_classes = None
    self.n_clusters = None
    self.alpha = alpha
    self.L = L
    self.style = style
    self.n_clusters = m
    self.examples_per_cluster = d
    self.variances = torch.tensor([0.0])
def __init__(self, m, d, alpha=1.0, L=128, style='closest'):
    super(MagnetLoss, self).__init__()
    self.r = None
    self.classes = None
    self.clusters = None
    self.cluster_classes = None
    self.n_clusters = None
    self.alpha = alpha
    self.L = L
    self.style = style
    self.n_clusters = m
    self.examples_per_cluster = d
    self.variances = torch.tensor([0.0])