Skip to content
This repository was archived by the owner on Dec 27, 2019. It is now read-only.

L-BFGS#12

Merged
to266 merged 4 commits into
to266:masterfrom
sebasv:l-bfgs
Dec 1, 2018
Merged

L-BFGS#12
to266 merged 4 commits into
to266:masterfrom
sebasv:l-bfgs

Conversation

@sebasv

@sebasv sebasv commented Nov 12, 2018

Copy link
Copy Markdown
Contributor

Implements a limited-memory BFGS variant. First step towards an L-BFGS-B routine. #2

TODO

  • max feval condition
  • max geval condition
  • documentation
  • convenience method that uses finite difference approximation for the gradient

@sebasv

sebasv commented Nov 20, 2018

Copy link
Copy Markdown
Contributor Author

Ready for review. Currently uses the golden ratio line search to determine step size, we could consider a trust region as well.

@to266 to266 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

LGTM, just one trivial comment below.

Thanks for the PR!

Comment thread src/vector/l_bfgs.rs
loop {
let dir = self.quasi_update(&g, &hist);
let a = {
let min = ::scalar::GoldenRatioBuilder::default()

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

How about moving this minimizer implementation outside the loop? Not sure this works, but I don't see any obvious reasons why not.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It has to do with ownership; min is passed a reference to x, so as long as min lives, x can not be mutated. That's why the whole shebang is in a block returning a.

@to266 to266 mentioned this pull request Nov 28, 2018
1 task
@to266 to266 merged commit 3f76177 into to266:master Dec 1, 2018
@sebasv sebasv deleted the l-bfgs branch January 6, 2019 19:53
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants