Skip to content

SVD didnot converge in application of spateo in HD platform #344

@Yukaixu666

Description

@Yukaixu666

Thank you so much for your earlier guidance on slice scale normalization—your suggestion to use separate_scale=True with minimal nonrigid transformation provided a crucial direction for our cross-slice alignment workflow.
After receiving your advice, we strictly implemented the solution as recommended, with the following detailed steps:
Input Data Quality Check: We verified that the spatial coordinates of both slice1 (K1) and slice2 (K2) contain no non-positive values (≤0), NaNs, Infs, or duplicate points. Specifically:
np.any(slice.obsm['spatial'] <= 0) returned False for both slices (ruling out log errors from non-positive values).
Deduplication via np.unique(coords, axis=0) showed no significant redundant cells, ensuring no matrix rank issues from duplicate coordinates.
Alignment Parameter Configuration: We used the exact parameters you suggested: beta=1e-4, lambdaVF=1e4, rep_layer='X_pca', and separate_scale=True. We also confirmed that obsm['X_pca'] (50 dimensions, standard for feature matching) was precomputed for both slices.
Environment & Dependency Validation: We ensured we are using the latest stable version of Spateo (v1.6.0) and PyTorch 2.0.1 (with CUDA 11.8 support). All dependencies were installed via conda to avoid version conflicts.
However, the system still throws errors similar to those reported earlier.

Image

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions