From 0a1ecfcf10947705422e96cdb7f9e0a72149e6dc Mon Sep 17 00:00:00 2001 From: Mateusz Baran Date: Mon, 16 Oct 2023 17:35:47 +0200 Subject: [PATCH] adapt to exp/retract unification --- src/Manifolds.jl | 2 ++ src/manifolds/VectorBundle.jl | 8 ++++++++ test/manifolds/circle.jl | 4 ---- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/Manifolds.jl b/src/Manifolds.jl index fe5dba1718..d0e48f4337 100644 --- a/src/Manifolds.jl +++ b/src/Manifolds.jl @@ -23,8 +23,10 @@ import ManifoldsBase: _access_nested, _get_basis, _injectivity_radius, + _inverse_retract, _inverse_retract!, _read, + _retract, _retract!, _write, active_traits, diff --git a/src/manifolds/VectorBundle.jl b/src/manifolds/VectorBundle.jl index e54387a718..340b847ba2 100644 --- a/src/manifolds/VectorBundle.jl +++ b/src/manifolds/VectorBundle.jl @@ -149,6 +149,10 @@ function inner(B::FiberBundle, p, X, Y) return inner(B.manifold, px, VXM, VYM) + inner(F, Vx, VXF, VYF) end +function _inverse_retract(M::FiberBundle, p, q, ::FiberBundleInverseProductRetraction) + return inverse_retract_product(M, p, q) +end + function _inverse_retract!(M::FiberBundle, X, p, q, ::FiberBundleInverseProductRetraction) return inverse_retract_product!(M, X, p, q) end @@ -251,6 +255,10 @@ which by default allocates and calls `retract_product!`. """ retract(::VectorBundle, p, q, t::Number, ::FiberBundleProductRetraction) +function _retract(M::VectorBundle, p, X, t::Number, ::FiberBundleProductRetraction) + return retract_product(M, p, X, t) +end + function retract_product(M::VectorBundle, p, X, t::Number) q = allocate_result(M, retract, p, X) return retract_product!(M, q, p, X, t) diff --git a/test/manifolds/circle.jl b/test/manifolds/circle.jl index 0187eb732b..d0ab19fd92 100644 --- a/test/manifolds/circle.jl +++ b/test/manifolds/circle.jl @@ -2,10 +2,6 @@ include("../utils.jl") using Manifolds: TFVector, CoTFVector -# TODO: remove after bug in StaticArray is fixed -@inline Base.copy(a::SizedArray) = __copy(a) -@inline __copy(a::SizedArray{S,T}) where {S,T} = SizedArray{S,T}(copy(a.data)) - @testset "Circle" begin M = Circle() @testset "Real Circle Basics" begin