search for triplets in minigrids, rows,  cols