Minor fix for rand_index