for i, row in enumerate(n):
    key = row[3]
if key not in keepers:
    keepers[key] = i, row[2]
elif row[2] > keepers[key][1]:
    deletions.append(i)
else:
    deletions.append(keepers[key][0])
keepers[key] = i, row[2]
o = numpy.delete(n, deletions, axis=0)
удаление строк массива numpy на основе уникальности значения