diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 415943bf8..465745d2f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,7 +7,7 @@ on: - develop - release** jobs: - test: + test-stable: name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} runs-on: ${{ matrix.os }} env: @@ -17,7 +17,6 @@ jobs: matrix: version: - '1.6' - - 'nightly' os: - ubuntu-latest arch: @@ -49,6 +48,44 @@ jobs: with: file: lcov.info + # hacky way to remove code coverage from nightly + test-nightly-nocov: + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} + runs-on: ${{ matrix.os }} + env: + JULIA_PKG_SERVER: "" + strategy: + fail-fast: false + matrix: + version: + - 'nightly' + os: + - ubuntu-latest + arch: + - x64 + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@v1 + with: + version: ${{ matrix.version }} + arch: ${{ matrix.arch }} + - uses: actions/cache@v1 + env: + cache-name: cache-artifacts + with: + path: ~/.julia/artifacts + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} + restore-keys: | + ${{ runner.os }}-test-${{ env.cache-name }}- + ${{ runner.os }}-test- + ${{ runner.os }}- + - uses: julia-actions/julia-buildpkg@latest + - run: | + git config --global user.name Tester + git config --global user.email te@st.er + - uses: julia-actions/julia-runtest@latest + continue-on-error: ${{ matrix.version == 'nightly' }} + upstream-dev: #if: github.ref != 'refs/heads/release**' name: Upstream Dev diff --git a/src/FactorGraph.jl b/src/FactorGraph.jl index 7d66f5121..e11ac249b 100644 --- a/src/FactorGraph.jl +++ b/src/FactorGraph.jl @@ -288,14 +288,14 @@ function resetVariable!(varid::VariableNodeData; for pt in pts fill!(pt, 0.0) end - pn = manikde!(pts, zeros(AMP.Ndim(val)), getManifolds(varid)) + pn = manikde!(getManifold(varid), pts, bw=zeros(Ndim(val))) setValKDE!(varid, pn, false, 0.0) # setVariableInferDim!(varid, 0) # setVariableInitialized!(vari, false) nothing end -resetVariable!(vari::DFGVariable; solveKey::Symbol=:default )::Nothing = resetVariable!(getSolverData(vari), solveKey=solveKey) +resetVariable!(vari::DFGVariable; solveKey::Symbol=:default ) = resetVariable!(getSolverData(vari), solveKey=solveKey) function resetVariable!(dfg::G, sym::Symbol; @@ -383,7 +383,6 @@ function setDefaultNodeData!( v::DFGVariable, sp = Int[0;] (valpts, bws) = if initialized pN = resample(getBelief(v)) - # pN = AMP.manikde!(randn(dims, N), getManifolds(varType)); bws = getBW(pN)[:,1:1] pNpts = getPoints(pN) isinit = true diff --git a/src/ParametricUtils.jl b/src/ParametricUtils.jl index 3efb8cda9..1e77d7642 100644 --- a/src/ParametricUtils.jl +++ b/src/ParametricUtils.jl @@ -381,7 +381,6 @@ struct MixedCircular <: Optim.Manifold isCircular::BitArray end -# FIXME getManifolds is being deprecated, use getManifold instead. function MixedCircular(fg::AbstractDFG, varIds::Vector{Symbol}) circMask = Bool[] for k = varIds diff --git a/src/TreeMessageUtils.jl b/src/TreeMessageUtils.jl index 0f83bbb5a..d9b8802be 100644 --- a/src/TreeMessageUtils.jl +++ b/src/TreeMessageUtils.jl @@ -313,7 +313,7 @@ function addLikelihoodsDifferentialCHILD!(cliqSubFG::AbstractDFG, # calculate the general deconvolution between variables pts, = approxDeconv(tfg, afc.label, solveKey) # solveFactorMeasurements # @show sft - newBel = manikde!(pts, sft) # getManifolds(sft) + newBel = manikde!(pts, sft) # replace dummy factor with real deconv factor using manikde approx belief measurement fullFct = _sft(newBel) deleteFactor!(tfg, afc.label) diff --git a/src/Variables/DefaultVariables.jl b/src/Variables/DefaultVariables.jl index c9c23d052..5f6f9328d 100644 --- a/src/Variables/DefaultVariables.jl +++ b/src/Variables/DefaultVariables.jl @@ -7,7 +7,7 @@ export Circular, Circle Base.convert(::Type{<:Tuple}, ::InstanceType{Manifolds.Euclidean{Tuple{N}, ℝ}} ) where N = tuple([:Euclid for i in 1:N]...) Base.convert(::Type{<:Tuple}, ::InstanceType{Manifolds.Circle{ℝ}}) = (:Circular,) -# Base.convert(::Type{<:Tuple}, mani::MB.AbstractManifold) = getManifolds(mani) + ## Euclid 1 @@ -22,10 +22,6 @@ DevNotes """ @defVariable ContinuousScalar TranslationGroup(1) [0.0;] -# Base.convert(::Type{<:ManifoldsBase.AbstractManifold}, ::InstanceType{ContinuousScalar}) = Manifolds.Euclidean(1) - - -## Euclid N """ @@ -37,10 +33,9 @@ struct ContinuousEuclid{N} <: InferenceVariable end ContinuousEuclid(x::Int) = ContinuousEuclid{x}() # not sure if these overloads are necessary since DFG 775? -DFG.getManifold(::InstanceType{ContinuousEuclid{N}}) where N = TranslationGroup(N) -# DFG.getManifold(::ContinuousEuclid{N}) where N = TranslationGroup(N) +DFG.getManifold(::InstanceType{ContinuousEuclid{N}}) where N = TranslationGroup(N) DFG.getDimension(val::InstanceType{ContinuousEuclid{N}}) where N = manifold_dimension(getManifold(val)) -# DFG.getDimension(val::ContinuousEuclid{N}) where N = manifold_dimension(getManifold(val)) + DFG.getPointType(::Type{ContinuousEuclid{N}}) where N = Vector{Float64} DFG.getPointIdentity(M_::Type{ContinuousEuclid{N}}) where N = zeros(N) # identity_element(getManifold(M_), zeros(N)) @@ -60,8 +55,6 @@ Circular is a `Manifolds.Circle{ℝ}` mechanization of one rotation, with `theta @defVariable Circular Circle() [0.0;] -# Base.convert(::Type{<:ManifoldsBase.AbstractManifold}, ::InstanceType{Circular}) = Manifolds.Circle() - # \ No newline at end of file