why import, reload, import again?

beliavsky at aol.com beliavsky at aol.com
Tue Jan 3 17:06:36 EST 2006

Near the beginning of file test_matrix.py from scipy are the lines

import scipy.base
from scipy.base import *
del sys.path[0]

Could someone please explain why the first two lines were included? A
similar script I wrote works fine without them. Also, what is the
purpose of the "del" line? (I understand the mechanics of what "del"
does.) The scipy developers are skilled Python programmers, so I am
trying to understand the idioms used in their codes.

More information about the Python-list mailing list