minor code maintenance to keep up with changes in the package structure of scipy