Skip to content

Commit

Permalink
Merge pull request #658 from JuliaRobotics/23Q1/enh/dfg20
Browse files Browse the repository at this point in the history
updates for DFG v0.20 and IIF v0.33
  • Loading branch information
dehann committed Mar 11, 2023
2 parents 7353ae1 + 5a79f48 commit ee5b195
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
7 changes: 3 additions & 4 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ TransformUtils = "9b8138ad-1b09-5408-aa39-e87ed6d21b63"
[compat]
ApproxManifoldProducts = "0.6.2"
CoordinateTransformations = "0.5, 0.6"
DistributedFactorGraphs = "0.19, 0.20"
DistributedFactorGraphs = "0.20"
Distributions = "0.24, 0.25"
DocStringExtensions = "0.8, 0.9"
FileIO = "1"
IncrementalInference = "0.32"
IncrementalInference = "0.33"
JLD2 = "0.3, 0.4"
KernelDensityEstimate = "0.5.1, 0.6"
Manifolds = "0.8.11"
Expand All @@ -62,9 +62,8 @@ Flux = "587475ba-b771-5e3f-ad9e-33799f191a9c"
ImageCore = "a09fc81d-aa75-5fe9-8630-4744c3626534"
ImageIO = "82e4d734-157c-48bb-816b-45c225c6df19"
Interpolations = "a98d9a8b-a2ab-59e6-89dd-64a1c18fca59"
JSON2 = "2535ab7d-5cd8-5a07-80ac-9b1792aadce3"
JSON3 = "0f8b85d8-7281-11e9-16c2-39a750bddbf1"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["Flux", "ImageCore", "ImageIO", "Interpolations", "JSON2", "JSON3", "Test"]
test = ["Flux", "ImageCore", "ImageIO", "Interpolations", "JSON3", "Test"]
9 changes: 9 additions & 0 deletions test/testPoint2Point2.jl
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,15 @@ point2point2rangeString = """
jback = JSON3.read(point2point2rangeString, PackedFactor)
f = unpackFactor(fg, jback)

# f1 = addFactor!(fg, [:x0, :l3], Point2Point2Range(Normal(89.44271909999159, 3.0)); inflation=5, graphinit=false)
# pf = DFG.packFactor(fg, f1)
# jstr = JSON3.write(pf)
point2point2rangeString = "{\"label\":\"x0l3f1\",\"tags\":[\"FACTOR\"],\"_variableOrderSymbols\":[\"x0\",\"l3\"],\"timestamp\":\"2023-03-10T17:28:37.230-08:00\",\"nstime\":0,\"fnctype\":\"Point2Point2Range\",\"solvable\":1,\"data\":\"{\\\"eliminated\\\":false,\\\"potentialused\\\":false,\\\"edgeIDs\\\":[],\\\"fnc\\\":{\\\"Z\\\":{\\\"_type\\\":\\\"IncrementalInference.PackedNormal\\\",\\\"mu\\\":89.44271909999159,\\\"sigma\\\":3.0}},\\\"multihypo\\\":[],\\\"certainhypo\\\":[1,2],\\\"nullhypo\\\":0.0,\\\"solveInProgress\\\":0,\\\"inflation\\\":5.0}\",\"metadata\":\"e30=\",\"_version\":\"0.20.0\"}"

f_ = JSON3.read(point2point2rangeString, DFG.PackedFactor)
f = DFG.unpackFactor(fg, f_)

addFactor!(fg, f)

##
end
Expand Down
Binary file modified test/testdata/g2otest.tar.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion test/testpackingconverters.jl
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ global unpackeddata = reconstFactorData(fg, getVariableOrder(f1), IncrementalInf
# @test compareAll(DFG.getSolverData(f1).fnc.cpt[1], unpackeddata.fnc.cpt[1], skip=[:factormetadata;:activehypo])

# @test compareAll(DFG.getSolverData(f1).fnc.params, unpackeddata.fnc.params)
@warn "threadmodel is not defined, fix with DFG"
@warn "threadmodel is obsolete"
# @test compareAll(DFG.getSolverData(f1).fnc.threadmodel, unpackeddata.fnc.threadmodel)

# TODO: Ref above
Expand Down

0 comments on commit ee5b195

Please sign in to comment.