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

Define precision for Dual #580

Merged
merged 4 commits into from
Apr 24, 2022
Merged

Define precision for Dual #580

merged 4 commits into from
Apr 24, 2022

Conversation

devmotion
Copy link
Member

Similar to eps, this PR adds an implementation of precision(::Dual) and precision(::Type{<:Dual}), with support of the base keyword argument in Julia 1.8.

This is useful e.g. in LogExpFunctions (JuliaStats/LogExpFunctions.jl#37 (comment)) to define precision-specific branches.

@codecov-commenter
Copy link

codecov-commenter commented Mar 8, 2022

Codecov Report

Merging #580 (818936a) into master (eed0ff3) will decrease coverage by 0.03%.
The diff coverage is 40.00%.

❗ Current head 818936a differs from pull request most recent head 8fd9293. Consider uploading reports for the commit 8fd9293 to get more accurate results

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #580      +/-   ##
==========================================
- Coverage   85.31%   85.28%   -0.04%     
==========================================
  Files           9        9              
  Lines         858      856       -2     
==========================================
- Hits          732      730       -2     
  Misses        126      126              
Impacted Files Coverage Δ
src/dual.jl 74.25% <40.00%> (-0.08%) ⬇️
src/partials.jl 84.21% <0.00%> (-0.14%) ⬇️
src/gradient.jl 98.87% <0.00%> (-0.03%) ⬇️
src/jacobian.jl 99.31% <0.00%> (-0.01%) ⬇️
src/prelude.jl 37.50% <0.00%> (+1.13%) ⬆️

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 eed0ff3...8fd9293. Read the comment docs.

@cossio
Copy link
Contributor

cossio commented Mar 11, 2022

Can this be merged?
If possible tagging a release as well.

Copy link
Contributor

@tpapp tpapp left a comment

Choose a reason for hiding this comment

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

LGTM.

@mcabbott mcabbott merged commit e11936c into master Apr 24, 2022
@mcabbott mcabbott deleted the dw/precision branch April 24, 2022 00:36
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.

5 participants