// it has the max possible value: 65535 (max unsigned int16)
// so it"ll be always as first index
_count[i:, range(i+1)] = list(_count[range(i), i]) + [np.iinfo(np.uint16).max]
for j in range(i+1, n):
_count[i, j] = _dist(ind[i], ind[j])
return np.flip(np.argsort(_count), axis=1)[:, range(1, self.ref_set+1)]
def _sod(self):
After Change
// but we need it temporarily to maintain indices order,
// it has the max possible value: 65535 (max unsigned int16)
// so it"ll be always as first index
temp = np.sum(np.isin(ind, ind[i]), axis=1).ravel()
temp[i] = np.iinfo(np.uint16).max
_count[i] = temp
return np.flip(np.argsort(_count), axis=1)[:, range(1, self.ref_set + 1)]