Fix backward compatibility issue with numpy.

Signed-off-by: Martin Raspaud <martin.raspaud@smhi.se>