Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DOC: optimize: separate legacy interfaces from new ones #8889

Merged
merged 3 commits into from
Jun 5, 2018

Conversation

antonior92
Copy link
Member

Hi all, in this PR I try to improve the structure of scipy.optimize API reference.

I tried to separate the new interfaces, such as minimize and root, from the deprecated ones. I think this should make the API reference easier to navigate for new users (and for the more experienced users as well).

@antonior92 antonior92 added scipy.optimize Documentation Issues related to the SciPy documentation. Also check https://github.com/scipy/scipy.org query A question or suggestion that requires further information needs-decision Items that need further discussion before they are merged or closed labels May 30, 2018
@josef-pkt
Copy link
Member

The multivariate fminxxx are not really deprecated, are they?

I don't remember seeing a decision to deprecate them.

@antonior92
Copy link
Member Author

Ok, maybe deprecated is the wrong word.

But they are interfaces that should be avoided in new scripts and I think it would improve the documentation to separate them from the newer and more consistent interfaces.

Maybe I can just change the section name to "Old Interfaces"

@dlax
Copy link
Member

dlax commented May 30, 2018

Perhaps "legacy" is a more appropriate term than "deprecated".

@antonior92 antonior92 changed the title DOC: optimize: separate deprecated interfaces from new ones DOC: optimize: separate legacy interfaces from new ones May 30, 2018
@antonior92
Copy link
Member Author

antonior92 commented May 30, 2018

Thank you @dlax. "Legacy" is a much better term for describing this functions.

@rgommers
Copy link
Member

This restructuring seems like a good idea to me.

@antonior92
Copy link
Member Author

Thank you all for the comments. I have just amend a few minor modifications.

Anyone, please let me know if there are other parts that need to be improved or better choice of words that I could use.


show_options - Show specific options optimization solvers
LbfgsInvHessProduct - Linear operator for L-BFGS approximate inverse Hessian
HessianUpdateStrategy - Interface for implementing Hessian update strategies
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that the HessianUpdateStrategy line got dropped (unless I missed it). I guess it should stay along with LbfgsInvHessProduct in "Hessian Approximation" section above.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, just included this line back.

@antonior92
Copy link
Member Author

For easy reference, the documentation can be accessed through this link:
https://7187-1460385-gh.circle-artifacts.com/0/html-scipyorg/optimize.html

@twmr
Copy link
Contributor

twmr commented Jun 5, 2018

Does it make sense to deprecate those legacy optimizers and throw them out in future release?

@rgommers
Copy link
Member

rgommers commented Jun 5, 2018

Does it make sense to deprecate those legacy optimizers and throw them out in future release?

Not really, they're very widely used and they're not broken. We've decided to leave them in place, and just in the docs direct people to the newer interface.

@josef-pkt
Copy link
Member

Does it make sense to deprecate those legacy optimizers and throw them out in future release?

statsmodels still relies dominantly on the "legacy" interface, even though we have minimize now as optional method.
Changing this would be quite a bit of work, and would need a lot of checking. The scipy optimizers are at the core of almost all our model estimation. So if something doesn't work it would have a very large impact.
scipy minimize looks stable enough now, I guess even for the minimum scipy version that statsmodels supports, so I would not rule out anymore switching over to minimize, but it's still low priority work given that the current interface has worked for us for 8 or 9 years.

@josef-pkt
Copy link
Member

To add to statsmodels comment:
We have not added any new wrappers since basinhopping, so we need to go through minimize for the newer optimizers. This will most likely lead to a slow migration to have more parts using the minimize interface, for now the main default methods are still fmin_bfgs and fmin_lbfgsb.

@dlax dlax merged commit 0836727 into scipy:master Jun 5, 2018
@antonior92 antonior92 deleted the optimize-doc branch June 5, 2018 15:49
@rgommers rgommers removed needs-decision Items that need further discussion before they are merged or closed query A question or suggestion that requires further information labels Jun 5, 2018
@rgommers rgommers added this to the 1.2.0 milestone Jun 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Issues related to the SciPy documentation. Also check https://github.com/scipy/scipy.org scipy.optimize
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants