def coords2index(self, i, j):
        assert 0 <= i < self.m
        assert 0 <= j < self.n
        return i * self.n + j
dataset/ETHPy150Open azoft-dev-team/imagrium/env/Lib/test/test_generators.py/Knights.coords2index/original