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

Convergence Logging #32

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mileslucas
Copy link

Fixes #27

Here's what I've got started in terms of convergence logging. I'd really like this feature and want to help get it done. Unfortunately, I have extremely little macro knowledge so I haven't dived into that. I would fully appreciate contributions to this regard.

This design is basically what @tkf wrote out in this comment. I've mimicked some of the code for the Progress struct and can get the following behavior:

julia> using ProgressLogging: Convergence, Ascending, Descending
julia> using UUIDs: UUID
julia> print(Convergence(UUID(1); values=[12, 13], thresholds=[5, 5]))
Convergence: 12.0|5.0
Convergence: 13.0|5.0

julia> print(Convergence(UUID(1); values=[12, 13], thresholds=[5, 5], directions=fill(Ascending, 2), step=4))
4 Convergence: 12.05.0
4 Convergence: 13.05.0

julia> print(Convergence(UUID(1); values=[12, 13], thresholds=[5, 5], directions=fill(Descending, 2)))
Convergence: 12.05.0
Convergence: 13.05.0

julia> print(Convergence(UUID(1); values=[12, 13]))
Convergence: 12.0|??
Convergence: 13.0|??

julia> print(Convergence(UUID(1); names=["A", "B"]))
A: ??|??
B: ??|??

@codecov-commenter
Copy link

codecov-commenter commented Jul 22, 2020

Codecov Report

Merging #32 into master will decrease coverage by 9.35%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #32      +/-   ##
==========================================
- Coverage   69.04%   59.69%   -9.36%     
==========================================
  Files           1        2       +1     
  Lines         168      196      +28     
==========================================
+ Hits          116      117       +1     
- Misses         52       79      +27     
Impacted Files Coverage Δ
src/ProgressLogging.jl 69.23% <ø> (+0.18%) ⬆️
src/convergence.jl 0.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 10208bc...0408558. Read the comment docs.

@mileslucas mileslucas marked this pull request as draft July 22, 2020 20:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Convergence logging
2 participants