def __init__(self, grid, translations, names='dual vs angle', locs=[(0, 0), ((- 1), (- 1))], log_every=500):
    self.print = False
    self.locs = []
    (tx, ty) = translations
    for loc in locs:
        self.locs.append(((grid[:, 1] == tx[loc[0]]) & (grid[:, 2] == ty[loc[1]])))
    if isinstance(names, str):
        names = [f'{names} {(grid[(i[0], 1)].detach().cpu().item(), grid[(i[0], 2)].detach().cpu().item())}' for i in locs]
    self.grid = grid
    self.meters = [WBLinePlotMeter(name) for name in names]
    self.log_every = log_every
    self.counter = 0
def __init__(self, grid, translations, names='dual vs angle', locs=[(0, 0), ((- 1), (- 1))], log_every=500):
    self.print = False
    self.locs = []
    (tx, ty) = translations
    for loc in locs:
        self.locs.append(((grid[:, 1] == tx[loc[0]]) & (grid[:, 2] == ty[loc[1]])))
    if isinstance(names, str):
        names = [f'{names} {(grid[(i[0], 1)].detach().cpu().item(), grid[(i[0], 2)].detach().cpu().item())}' for i in locs]
    self.grid = grid
    self.meters = [WBLinePlotMeter(name) for name in names]
    self.log_every = log_every
    self.counter = 0