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

Step by step linesearch #45

Open
Goysa2 opened this issue May 10, 2017 · 5 comments
Open

Step by step linesearch #45

Goysa2 opened this issue May 10, 2017 · 5 comments

Comments

@Goysa2
Copy link

Goysa2 commented May 10, 2017

Hi,

Sorry to create another issue with an easy question, but I was wondering if there is a way to display each iteration of a line search algorithm.

The basic example on show the results but I'd like to see every step of the process.

Thank you very much!

@anriseth
Copy link
Collaborator

anriseth commented May 10, 2017

hagerzhang! has verbosity options via the display parameter: https://github.com/JuliaNLSolvers/LineSearches.jl/blob/master/src/hagerzhang.jl (I don't know exactly how the bitwise operations work, this was created long before my time with the package)

It doesn't seem like the other linesearches have any inbuilt support for verbose output.
PRs are welcome 😄

@Goysa2
Copy link
Author

Goysa2 commented May 10, 2017

thank you very much once again!

@pkofod
Copy link
Member

pkofod commented Jun 2, 2017

(I don't know exactly how the bitwise operations work, this was created long before my time with the package)

That is a pretty weird way of specifying it. Basically if display has the same bit at the same place as either of the options, it will print. Say it was in binary instead, it would print final output if display was 000001 (as bitwise comparison between display and final will return 000001) and it would print iter if display was 000010 (1 << 1 is 2 so it is 01), and it would print parameters if display was 000100 (4). Then if you enter 6 instead (000110) it will plrint parameters and iter info, and if you enter 7 (000111) it will print final, iter, and parameter info. We should probably change this, haha.

@anriseth
Copy link
Collaborator

anriseth commented Jun 2, 2017 via email

@pkofod
Copy link
Member

pkofod commented Jun 2, 2017

Hehe, yes it looks like a remnant of the original FORTRAN(?) code. I tried to enable display a year ago, but gave up as I didn't know what datatype to use (if I remember correctly, Int was not good enough)

a tuple?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants