pub struct ProductManifoldConfig {
pub euclidean_dim: usize,
pub hyperbolic_dim: usize,
pub hyperbolic_curvature: f64,
pub spherical_dim: usize,
pub spherical_curvature: f64,
pub component_weights: (f64, f64, f64),
}Expand description
Configuration for a product manifold
Fields§
§euclidean_dim: usizeEuclidean dimension
hyperbolic_dim: usizeHyperbolic dimension (Poincaré ball ambient dimension)
hyperbolic_curvature: f64Hyperbolic curvature (negative)
spherical_dim: usizeSpherical dimension (ambient dimension)
spherical_curvature: f64Spherical curvature (positive)
component_weights: (f64, f64, f64)Weights for combining distances
Implementations§
Source§impl ProductManifoldConfig
impl ProductManifoldConfig
Sourcepub fn new(
euclidean_dim: usize,
hyperbolic_dim: usize,
spherical_dim: usize,
) -> Self
pub fn new( euclidean_dim: usize, hyperbolic_dim: usize, spherical_dim: usize, ) -> Self
Create a new product manifold configuration
§Arguments
euclidean_dim- Dimension of Euclidean component E^ehyperbolic_dim- Dimension of hyperbolic component H^hspherical_dim- Dimension of spherical component S^s
Sourcepub fn hyperbolic(dim: usize) -> Self
pub fn hyperbolic(dim: usize) -> Self
Create hyperbolic-only configuration
Sourcepub fn euclidean_hyperbolic(euclidean_dim: usize, hyperbolic_dim: usize) -> Self
pub fn euclidean_hyperbolic(euclidean_dim: usize, hyperbolic_dim: usize) -> Self
Create Euclidean × Hyperbolic configuration
Sourcepub fn with_hyperbolic_curvature(self, c: f64) -> Self
pub fn with_hyperbolic_curvature(self, c: f64) -> Self
Set hyperbolic curvature
Sourcepub fn with_spherical_curvature(self, c: f64) -> Self
pub fn with_spherical_curvature(self, c: f64) -> Self
Set spherical curvature
Sourcepub fn with_weights(
self,
euclidean: f64,
hyperbolic: f64,
spherical: f64,
) -> Self
pub fn with_weights( self, euclidean: f64, hyperbolic: f64, spherical: f64, ) -> Self
Set component weights for distance computation
Trait Implementations§
Source§impl Clone for ProductManifoldConfig
impl Clone for ProductManifoldConfig
Source§fn clone(&self) -> ProductManifoldConfig
fn clone(&self) -> ProductManifoldConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProductManifoldConfig
impl Debug for ProductManifoldConfig
Auto Trait Implementations§
impl Freeze for ProductManifoldConfig
impl RefUnwindSafe for ProductManifoldConfig
impl Send for ProductManifoldConfig
impl Sync for ProductManifoldConfig
impl Unpin for ProductManifoldConfig
impl UnwindSafe for ProductManifoldConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more