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

Return Residual in CalcFactor #1147

Merged
merged 1 commit into from
Feb 5, 2021
Merged

Conversation

Affie
Copy link
Member

@Affie Affie commented Feb 5, 2021

WIP towards #467

@codecov-io
Copy link

Codecov Report

Merging #1147 (583a1ca) into master (6ddd346) will increase coverage by 1.43%.
The diff coverage is 75.52%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1147      +/-   ##
==========================================
+ Coverage   70.27%   71.71%   +1.43%     
==========================================
  Files          55       55              
  Lines        4282     4613     +331     
==========================================
+ Hits         3009     3308     +299     
- Misses       1273     1305      +32     
Impacted Files Coverage Δ
src/Deprecated.jl 26.47% <0.00%> (-10.09%) ⬇️
src/FactorGraph.jl 73.75% <ø> (+1.79%) ⬆️
src/FactorGraphTypes.jl 100.00% <ø> (ø)
src/ParametricUtils.jl 65.38% <62.82%> (-2.41%) ⬇️
src/ApproxConv.jl 89.79% <92.85%> (+1.17%) ⬆️
src/CalcFactor.jl 80.76% <100.00%> (+3.49%) ⬆️
src/DeconvUtils.jl 60.00% <100.00%> (+1.86%) ⬆️
src/Factors/DefaultPrior.jl 52.94% <100.00%> (+17.64%) ⬆️
src/Factors/EuclidDistance.jl 33.33% <100.00%> (ø)
src/Factors/LinearRelative.jl 78.94% <100.00%> (+3.94%) ⬆️
... and 51 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 648aa8c...583a1ca. Read the comment docs.

src/NumericalCalculations.jl Show resolved Hide resolved
src/ParametricUtils.jl Show resolved Hide resolved
src/DeconvUtils.jl Show resolved Hide resolved
@@ -43,7 +43,7 @@ function _solveLambdaNumeric( fcttype::Union{F,<:Mixture{N_,F,S,T}},
#

#
r = nlsolve(objResX, u0, inplace=true)
r = nlsolve( (res, x) -> res .= objResX(x), u0, inplace=true)
Copy link
Member

Choose a reason for hiding this comment

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

Ah, you are doing the opposite of what I was doing. I had residual explicitly available for in-place operations (which we will still keep somewhere in CalcFactor.residual::T for hard in-place factor situations).

I see here now that you are changing to a more implicit usage of residual in the Roots (NLsolve.jl) case. I did not see this before, sorry if I missed it.

src/NumericalCalculations.jl Show resolved Hide resolved
Copy link
Member

@dehann dehann left a comment

Choose a reason for hiding this comment

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

@dehann dehann merged commit 8a1f722 into master Feb 5, 2021
@dehann dehann deleted the feature/21Q1/residual_return branch June 29, 2021 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants