tomodrgn.convergence#
Functions to aid estimation of model training convergence.
Functions
For each epoch in epochs, calculates the (auto-masked) correlation coefficient between each pair of volumes generated at that epoch. |
|
For each epoch in epochs, calculates the (auto-masked) correlation coefficient between each tomoDRGN volume and each ground_truth volume. |
|
For each successive pair of epochs in epochs, calculates the (auto-masked) correlation coefficient between the same particle's tomoDRGN-evaluated volume at those epochs. |
|
For each successive pair of epochs in epochs, calculates the (auto-masked) FSC between the same particle's tomoDRGN-evaluated volume at those epochs. |
|
Compute the KLD between two gaussians with diagomal covariance. |
|
Calculate the scale of heterogeneity among all volumes generated from test latent embeddings of the same particles in the same epoch |
|
Calculate the FSC between volumes generated from test and train latent embeddings of the same particles in the same epoch. |
|
Calculates and plots various metrics characterizing the per-particle latent vectors between successive epochs ranging between 0 and final_epoch. |
|
Plot how the labeled set of particles migrates within latent space at selected epochs over training. |
|
Calculate the Fourier Shell Correlation (FSC) between one reference volume and many query volumes. |
|
Select random particle indices and generate corresponding volumes using train-split images' latent embeddings and test-split latent embeddings. |
|
Calculates, saves, and plots PC1 vs PC2 for all particles' latent embeddings at selected epochs |
|
Calculates, plots, and saves UMAP embeddings of subset of particles' selected epochs' latent encodings |
|
Plot the total loss, reconstruction loss, and KLD divergence per epoch. |
|
Sketch one epoch's latent space via local maxima finding to find dense neighborhoods of particles with similar embeddings as "well-supported" by the data |