presto-main/src/main/java/io/prestosql/operator/RowNumberOperator.java/RowNumberOperator/getPartitionId
class RowNumberOperator:    private long getPartitionId(int position)
    {
        return isSinglePartition() ? 0 : partitionIds.getGroupId(position);
    }