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

Smart bounds for (s)pdmp #83

Merged
merged 4 commits into from
Jun 11, 2021
Merged

Smart bounds for (s)pdmp #83

merged 4 commits into from
Jun 11, 2021

Conversation

mschauer
Copy link
Owner

@mschauer mschauer commented Jun 7, 2021

No description provided.

@codecov-commenter
Copy link

codecov-commenter commented Jun 10, 2021

Codecov Report

Merging #83 (d2358dd) into master (0b961bf) will decrease coverage by 8.69%.
The diff coverage is 29.90%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #83      +/-   ##
==========================================
- Coverage   80.27%   71.57%   -8.70%     
==========================================
  Files          18       19       +1     
  Lines        1090     1256     +166     
==========================================
+ Hits          875      899      +24     
- Misses        215      357     +142     
Impacted Files Coverage Δ
src/ZigZagBoomerang.jl 100.00% <ø> (ø)
src/local.jl 0.00% <0.00%> (ø)
src/trace.jl 67.39% <0.00%> (-23.79%) ⬇️
src/poissontime.jl 85.00% <50.00%> (+0.78%) ⬆️
src/types.jl 81.25% <60.00%> (-10.42%) ⬇️
src/not_fact_samplers.jl 77.64% <72.58%> (-18.19%) ⬇️
src/dynamics.jl 100.00% <100.00%> (ø)
src/sfact.jl 87.70% <100.00%> (-0.10%) ⬇️
src/ss_not_fact.jl 93.65% <100.00%> (ø)
src/staticarrays.jl 100.00% <100.00%> (ø)
... and 2 more

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 da5eebb...d2358dd. Read the comment docs.

@mschauer
Copy link
Owner Author

pdmp is now internally working with a multi argument version of the gradient which also returns the change of the gradient in direction of the trajectory to compute smart bounds.

ℓ(x, args...) = ...
function gradients(ℓ, d)
    function (y, t, x, θ, args...)
        x_ = x + Dual{:Bz0iEasFfw}(0.0, 1.0)*θ
        y_ = ForwardDiff.gradient(x->-ℓ(x, args...), x_)
        y .= value.(y_)
        y, dot(θ, y_).partials[]
    end
end
∇ϕ! = gradients(ℓ, d)

Also update trace for bouncy, add cummean.

@mschauer mschauer changed the title Update trace for bouncy, add cummean Smart bounds for pdmp Jun 10, 2021
@mschauer mschauer changed the title Smart bounds for pdmp Smart bounds for (s)pdmp Jun 10, 2021
@mschauer mschauer merged commit 1ddb661 into master Jun 11, 2021
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.

2 participants