[SciPy-dev] openopt example mmp_1.py
Nils Wagner
nwagner at iam.uni-stuttgart.de
Sun Feb 3 04:04:57 EST 2008
On Sun, 03 Feb 2008 10:53:02 +0200
dmitrey <dmitrey.kroshko at scipy.org> wrote:
> Then I guess something have been changed in numpy (I
>have 1.0.3)
> here's full getCorrectInd() code:
>
> from numpy import *
> ....
> def getCorrectInd(p, ind):
> if ind is not None:
> if type(ind) in [int, int32, int64]: return [ind]
> elif type(ind) == ndarray: return
>atleast_1d(ind).tolist()
> elif type(ind) not in (list, tuple):
> p.err('incorrect func index type!')
> else: return ind
> else: return None
> So I can't understand why line "if type(ind) in [int,
>int32, int64]"
>
> Maybe ind32 is no longer available in recent numpy?
> Could you check
>
> from numpy import *
> a = int32(15)
>
>>> from numpy import *
>>> a = int32(15)
>>> a
15
>>> numpy.__version__
'1.0.5.dev4766'
Nils
More information about the SciPy-Dev
mailing list