work around numpy bug with empty arrays:
http://projects.scipy.org/numpy/ticket/1943