MAINT: make it work with scipy < 0.13