ENH: better 2d handling