[SciPy-dev] openopt example mmp_1.py

Alan G Isaac aisaac@american....
Mon Feb 4 07:05:00 CST 2008


> On Sun, Feb 03, 2008 at 11:39:02AM +0200, dmitrey wrote:
>> "if type(ind) in [int, int32, int64]: return [ind]"


On Mon, 4 Feb 2008, Stefan van der Walt apparently wrote:
> 'issubdtype' does the checking you require:
> import numpy as np 
> np.issubdtype(ind,int)


If one wanted to do such type checking,
what would be the advantage in this case
over isinstance(ind,int)?

Cheers,
Alan Isaac





More information about the Scipy-dev mailing list