def buildCell(self, diag, top, left, x, y): none = self.cellFactory(x, y, 0, None) result = max(LevMatrix.buildCell(self, diag, top, left, x, y), none, key=lambda x: x.weight) if result.weight > self.maxCell.weight: self.maxCell = result return result
def __init__(self, s, t): self.max_value = None LevMatrix.__init__(self, s, t, weight=weight)
def __init__(self, s, t): self.maxCell = LevMatrixCell(-1, -1, 0, None, None) LevMatrix.__init__(self, s, t, weight=lambda a, b: getPAMWeight(a, b))