Embedders¶
manify.embedders
¶
Tools for embedding data into Riemannian manifolds and product spaces.
The embedders module provides various ways to embed data into manifolds of constant or mixed curvature. The module includes:
coordinate_learning: Direct optimization of coordinates in a product manifold.siamese: Siamese network-based embedding for metric learning.vae: Variational autoencoders for learning representations in product manifolds._losses: Loss functions for measuring embedding quality._base: Base class for embedders.
CoordinateLearning(pm, random_state=None, device=None)
¶
Bases: BaseEmbedder
Coordinate learning method class.
This embedder implements the approach described in Gu et al., "Learning Mixed-Curvature Representations in Product Spaces". It directly optimizes point coordinates to preserve a given distance matrix, using Riemannian optimization techniques.
Trains point coordinates in a product manifold to match target distances.
This class optimizes the coordinates of points in a product manifold to match a given distance matrix. The optimization is performed in two phases:
- Burn-in phase: Initial optimization with a smaller learning rate to find a good starting configuration.
- Training phase: Fine-tuning of the coordinates with a larger learning rate, and optionally optimizing the scale factors (curvatures) of the manifold components.
The optimization uses Riemannian Adam optimizer to respect the manifold structure during gradient updates. The loss is computed based on the distortion between the pairwise distances in the embedding and the target distances.
For non-transductive settings, the class supports split between training and testing points, optimizing different combinations of distances (train-train, test-test, train-test).
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
69 70 | |
fit(X, D, test_indices=None, lr=0.01, burn_in_lr=0.001, curvature_lr=0.0, burn_in_iterations=2000, training_iterations=18000, loss_window_size=100, logging_interval=10)
¶
Fit the Coordinate Learning Embedder. Sets attributes embeddings_, loss_history_, and is_fitted_.
| Parameters: |
|
|---|
| Returns: |
|
|---|
| Raises: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 | |
transform(X=None)
¶
Transform data using learned embedding. This is not meaningful for new data during coordinate learning.
| Parameters: |
|
|---|
| Returns: |
|
|---|
| Raises: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 | |
fit_transform(X, D, **fit_kwargs)
¶
Transform data using learned embedding based on the provided distance matrix D.
This method overrides the base class method BaseEmbedder.fit_transform() to not use the input data X.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 | |
SiameseNetwork(pm, encoder, decoder=None, reconstruction_loss='mse', beta=1.0, random_state=None, device='cpu')
¶
Bases: BaseEmbedder, Module
Siamese network for embedding data into a product manifold space.
A Siamese network consists of an encoder network that maps input data to a latent representation in a product manifold, and optionally a decoder network that maps the latent representation back to the original feature space.
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/siamese.py
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |
encode(x)
¶
Encodes input data into the manifold embedding space.
Takes a batch of input data and passes it through the encoder network to obtain embeddings in the manifold.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
91 92 93 94 95 96 97 98 99 100 101 102 | |
decode(z)
¶
Decodes manifold embeddings back to the original input space.
Takes a batch of embeddings from the manifold space and passes them through the decoder network to reconstruct the original input data.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
104 105 106 107 108 109 110 111 112 113 114 115 116 | |
forward(x1, x2)
¶
Given two points, return their encodings, reconstructions, and embedding distance.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |
fit(X, D, lr=0.001, burn_in_lr=0.0001, curvature_lr=0.0, burn_in_iterations=1, training_iterations=9, loss_window_size=100, logging_interval=10, batch_size=32, clip_grad=True)
¶
Fit the SiameseNetwork embedder.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 | |
transform(X, D=None, batch_size=32, expmap=True)
¶
Transforms input data into manifold embeddings.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 | |
ProductSpaceVAE(pm, encoder, decoder, random_state=None, device='cpu', beta=1.0, reconstruction_loss=None, n_samples=16)
¶
Bases: BaseEmbedder, Module
Product Space Variational Autoencoder.
The probabilistic model is defined as:
- Prior: \(p(z) = \mathcal{WN}(z; \mu_0, I)\) (wrapped normal distribution centered at manifold origin)
- Likelihood: \(p_\theta(x|z) = \mathcal{N}(x; f_\theta(z), \sigma^2 I)\) or other reconstruction distribution
- Posterior approximation: \(q_\phi(z|x) = \mathcal{WN}(z; \mu_\phi(x), \Sigma_\phi(x))\)
where \(\mathcal{WN}\) is a wrapped normal distribution on the manifold.
The model is trained by maximizing the evidence lower bound (ELBO):
\(\mathcal{L}(\theta, \phi; x) = \mathbb{E}_{q_\phi(z|x)}[\log p_\theta(x|z)] - \beta \cdot D_{KL}(q_\phi(z|x) || p(z))\)
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/vae.py
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | |
encode(x)
¶
Encodes input data to obtain latent means and log-variances in the manifold.
This method processes input data through the encoder network to obtain parameters of the approximate posterior distribution \(q(z|x)\) in the product manifold space. For non-Euclidean components, the method:
- Gets tangent space vectors and log-variances from the encoder,
- Projects tangent vectors to the ambient space by adding zeros in the right places, and
- Maps the ambient space vectors to the manifold using the exponential map
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 | |
decode(z)
¶
Decodes latent points from the manifold space back to the input space.
Takes points from the product manifold latent space and passes them through the decoder network to reconstruct the original input data.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |
forward(x)
¶
Performs the forward pass of the VAE in product manifold space.
This method implements the complete VAE forward pass, with manifold projection:
- Encode the input to get posterior parameters (
z_means,z_logvars) - Project means onto the manifold using exponential map
- Factorize the log-variances for each manifold component and convert to covariance matrices
- Sample points from the posterior distributions in the product manifold
- Decode the sampled points to get reconstructions
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 | |
kl_divergence(z_mean, sigma_factorized)
¶
Computes the KL divergence between posterior and prior distributions in the manifold.
For distributions in Riemannian manifolds, computing the KL divergence analytically is often intractable. This method uses Monte Carlo sampling to approximate the KL divergence:
where \(z_i\) are samples from \(q(z|x)\).
This implementation follows the approach described in: http://joschu.net/blog/kl-approx.html
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | |
elbo(x)
¶
Computes the Evidence Lower Bound (ELBO) for the VAE objective.
The ELBO is the standard objective function for variational autoencoders, consisting of a reconstruction term (log-likelihood) and a regularization term (KL divergence):
where:
- \(\theta\) are the decoder parameters
- \(\phi\) are the encoder parameters
- \(\beta\) is a weight for the KL term (setting \(\beta < 1\) creates a \(\beta\)-VAE)
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 | |
fit(X, D=None, lr=0.001, burn_in_lr=0.0001, curvature_lr=0.0, burn_in_iterations=1, training_iterations=9, loss_window_size=100, logging_interval=10, batch_size=32, clip_grad=True)
¶
Trains the VAE model on the provided data.
The training process consists of two phases:
- Burn-in phase: Initial training with a lower learning rate for stability
- Main training phase: Training with the full learning rate and optional curvature optimization
Training uses Adam optimizer with gradient clipping to prevent exploding gradients. During training, the model maximizes the Evidence Lower Bound (ELBO).
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 | |
transform(X, D=None, batch_size=32, expmap=True)
¶
Transform data using the trained VAE. Outputs means of the variational distribution.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 | |
coordinate_learning
¶
Implementation for direct coordinate optimization in Riemannian manifolds.
This module provides functions for learning optimal embeddings in product manifolds by directly optimizing the coordinates using Riemannian optimization. This approach is particularly useful for embedding graphs using metric learning to maintain pairwise distances in the target space. The optimization is performed using Riemannian gradient descent with support for non-transductive training, in which gradients from the test set to the training set are masked out.
CoordinateLearning(pm, random_state=None, device=None)
¶
Bases: BaseEmbedder
Coordinate learning method class.
This embedder implements the approach described in Gu et al., "Learning Mixed-Curvature Representations in Product Spaces". It directly optimizes point coordinates to preserve a given distance matrix, using Riemannian optimization techniques.
Trains point coordinates in a product manifold to match target distances.
This class optimizes the coordinates of points in a product manifold to match a given distance matrix. The optimization is performed in two phases:
- Burn-in phase: Initial optimization with a smaller learning rate to find a good starting configuration.
- Training phase: Fine-tuning of the coordinates with a larger learning rate, and optionally optimizing the scale factors (curvatures) of the manifold components.
The optimization uses Riemannian Adam optimizer to respect the manifold structure during gradient updates. The loss is computed based on the distortion between the pairwise distances in the embedding and the target distances.
For non-transductive settings, the class supports split between training and testing points, optimizing different combinations of distances (train-train, test-test, train-test).
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
69 70 | |
fit(X, D, test_indices=None, lr=0.01, burn_in_lr=0.001, curvature_lr=0.0, burn_in_iterations=2000, training_iterations=18000, loss_window_size=100, logging_interval=10)
¶
Fit the Coordinate Learning Embedder. Sets attributes embeddings_, loss_history_, and is_fitted_.
| Parameters: |
|
|---|
| Returns: |
|
|---|
| Raises: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 | |
transform(X=None)
¶
Transform data using learned embedding. This is not meaningful for new data during coordinate learning.
| Parameters: |
|
|---|
| Returns: |
|
|---|
| Raises: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 | |
fit_transform(X, D, **fit_kwargs)
¶
Transform data using learned embedding based on the provided distance matrix D.
This method overrides the base class method BaseEmbedder.fit_transform() to not use the input data X.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/coordinate_learning.py
228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 | |
siamese
¶
Siamese network implementation for manifold embedding.
This module provides a Siamese network architecture that can be used for embedding data into product manifolds. Siamese networks are particularly useful for metric learning tasks, where the goal is to learn a distance-preserving embedding, while also encoding a set of features.
The SiameseNetwork class supports both encoding (embedding) data into a manifold space and optionally decoding (reconstructing) from the embedding space back to the original data space.
SiameseNetwork(pm, encoder, decoder=None, reconstruction_loss='mse', beta=1.0, random_state=None, device='cpu')
¶
Bases: BaseEmbedder, Module
Siamese network for embedding data into a product manifold space.
A Siamese network consists of an encoder network that maps input data to a latent representation in a product manifold, and optionally a decoder network that maps the latent representation back to the original feature space.
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/siamese.py
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |
encode(x)
¶
Encodes input data into the manifold embedding space.
Takes a batch of input data and passes it through the encoder network to obtain embeddings in the manifold.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
91 92 93 94 95 96 97 98 99 100 101 102 | |
decode(z)
¶
Decodes manifold embeddings back to the original input space.
Takes a batch of embeddings from the manifold space and passes them through the decoder network to reconstruct the original input data.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
104 105 106 107 108 109 110 111 112 113 114 115 116 | |
forward(x1, x2)
¶
Given two points, return their encodings, reconstructions, and embedding distance.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |
fit(X, D, lr=0.001, burn_in_lr=0.0001, curvature_lr=0.0, burn_in_iterations=1, training_iterations=9, loss_window_size=100, logging_interval=10, batch_size=32, clip_grad=True)
¶
Fit the SiameseNetwork embedder.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 | |
transform(X, D=None, batch_size=32, expmap=True)
¶
Transforms input data into manifold embeddings.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/siamese.py
269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 | |
vae
¶
Variational autoencoder implementation for product manifold spaces.
This module provides a variational autoencoder (VAE) implementation specifically designed for learning representations in mixed-curvature product spaces. The implementation handles the complexities of sampling, KL divergence calculation, and reparameterization in curved spaces, supporting combinations of hyperbolic, Euclidean, and spherical geometries within a single latent space.
For more information, see Skopek et al (2020): Mixed Curvature Variational Autoencoders
ProductSpaceVAE(pm, encoder, decoder, random_state=None, device='cpu', beta=1.0, reconstruction_loss=None, n_samples=16)
¶
Bases: BaseEmbedder, Module
Product Space Variational Autoencoder.
The probabilistic model is defined as:
- Prior: \(p(z) = \mathcal{WN}(z; \mu_0, I)\) (wrapped normal distribution centered at manifold origin)
- Likelihood: \(p_\theta(x|z) = \mathcal{N}(x; f_\theta(z), \sigma^2 I)\) or other reconstruction distribution
- Posterior approximation: \(q_\phi(z|x) = \mathcal{WN}(z; \mu_\phi(x), \Sigma_\phi(x))\)
where \(\mathcal{WN}\) is a wrapped normal distribution on the manifold.
The model is trained by maximizing the evidence lower bound (ELBO):
\(\mathcal{L}(\theta, \phi; x) = \mathbb{E}_{q_\phi(z|x)}[\log p_\theta(x|z)] - \beta \cdot D_{KL}(q_\phi(z|x) || p(z))\)
| Attributes: |
|
|---|
| Parameters: |
|
|---|
Source code in manify/embedders/vae.py
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | |
encode(x)
¶
Encodes input data to obtain latent means and log-variances in the manifold.
This method processes input data through the encoder network to obtain parameters of the approximate posterior distribution \(q(z|x)\) in the product manifold space. For non-Euclidean components, the method:
- Gets tangent space vectors and log-variances from the encoder,
- Projects tangent vectors to the ambient space by adding zeros in the right places, and
- Maps the ambient space vectors to the manifold using the exponential map
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 | |
decode(z)
¶
Decodes latent points from the manifold space back to the input space.
Takes points from the product manifold latent space and passes them through the decoder network to reconstruct the original input data.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |
forward(x)
¶
Performs the forward pass of the VAE in product manifold space.
This method implements the complete VAE forward pass, with manifold projection:
- Encode the input to get posterior parameters (
z_means,z_logvars) - Project means onto the manifold using exponential map
- Factorize the log-variances for each manifold component and convert to covariance matrices
- Sample points from the posterior distributions in the product manifold
- Decode the sampled points to get reconstructions
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 | |
kl_divergence(z_mean, sigma_factorized)
¶
Computes the KL divergence between posterior and prior distributions in the manifold.
For distributions in Riemannian manifolds, computing the KL divergence analytically is often intractable. This method uses Monte Carlo sampling to approximate the KL divergence:
where \(z_i\) are samples from \(q(z|x)\).
This implementation follows the approach described in: http://joschu.net/blog/kl-approx.html
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | |
elbo(x)
¶
Computes the Evidence Lower Bound (ELBO) for the VAE objective.
The ELBO is the standard objective function for variational autoencoders, consisting of a reconstruction term (log-likelihood) and a regularization term (KL divergence):
where:
- \(\theta\) are the decoder parameters
- \(\phi\) are the encoder parameters
- \(\beta\) is a weight for the KL term (setting \(\beta < 1\) creates a \(\beta\)-VAE)
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 | |
fit(X, D=None, lr=0.001, burn_in_lr=0.0001, curvature_lr=0.0, burn_in_iterations=1, training_iterations=9, loss_window_size=100, logging_interval=10, batch_size=32, clip_grad=True)
¶
Trains the VAE model on the provided data.
The training process consists of two phases:
- Burn-in phase: Initial training with a lower learning rate for stability
- Main training phase: Training with the full learning rate and optional curvature optimization
Training uses Adam optimizer with gradient clipping to prevent exploding gradients. During training, the model maximizes the Evidence Lower Bound (ELBO).
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 | |
transform(X, D=None, batch_size=32, expmap=True)
¶
Transform data using the trained VAE. Outputs means of the variational distribution.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in manify/embedders/vae.py
367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 | |