[Scipy-tickets] [SciPy] #1126: scipy.optimize.anneal does not respect lower/upper bounds

SciPy Trac scipy-tickets@scipy....
Wed Apr 11 14:24:13 CDT 2012

#1126: scipy.optimize.anneal does not respect lower/upper bounds
 Reporter:  lboussouf                  |       Owner:  somebody    
     Type:  defect                     |      Status:  needs_review
 Priority:  high                       |   Milestone:  Unscheduled 
Component:  scipy.optimize             |     Version:              
 Keywords:  bounds upper lower anneal  |  

Comment(by josefpktd):

 I think it might be better to put the inrange check with a loop for
 drawing new random values. This would avoid the calculations with out of
 bounds values.

 something like (just typed not checked

 in_range = False
 for i in xrange(max_tries):
     current_state.x = schedule.update_guess(last_state.x)
     in_range = ...
     if in_range: break

 I'm not sure what should happen if max_tries are unsuccessful, go to next
 iteration and let the system cool?

 It might be necessary to check that the starting values are inside the
 bounds, or find starting values that are inside the bounds. I didn't check
 the details, but it could be possible that the search area (for random
 draws) and the bounds don't overlap with widely wrong starting values.

Ticket URL: <http://projects.scipy.org/scipy/ticket/1126#comment:9>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.

More information about the Scipy-tickets mailing list