[SciPy-dev] connecting tnc 1.3

dmitrey openopt@ukr....
Thu Jul 26 02:37:38 CDT 2007


Ok, I committed scipy rev 3193 with +/-numpy.inf instead of +/-HUGE_VAL
I checked in Python 2.5 all is OK
But I'm not sure that all OS, C compilers and hardware platforms will 
handle the numpy.inf correctly.

Updates to documentation and new tests had been implemented from 
scipy.newoptimize, seems like they are more detailed here. Also, 
test38fg contains arg2 being numpy.array, not python list, and works 
correctly (was committed earlier).

However, maybe x from tnc output is also better do as numpy.ndarray, not 
Python list?

Regards, D.


Stefan van der Walt wrote:
> Hi Dmitrey
>
> On Tue, Jul 24, 2007 at 11:38:31AM +0300, dmitrey wrote:
>   
>> hi all,
>> So now I'm trying to make all the tests for tnc 1.3 running ok.
>> But there is a problem encountered:
>>
>> here's a code from tnc.py, lines 210-213:
>>
>>     for i in range(n):
>>         l,u = bounds[i]
>>         if l is None:
>>             low[i] = -HUGE_VAL
>>
>>
>> So if bounds are for example ([-inf, -1.5], None), as it is written in 
>> test1fg(x), it yields error "None object is not iterable".
>> (because it tries to get
>> lb, ub = None
>> )
>>     
>
> You may want to replace all instances of HUGE_VAL with inf, as was
> done in
>
> http://projects.scipy.org/scipy/scipy/changeset/3037
>
> That changeset also updated the documentation and refactored the tests.
>
> Regards
> Stéfan
> _______________________________________________
> Scipy-dev mailing list
> Scipy-dev@scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-dev
>
>
>
>   



More information about the Scipy-dev mailing list