-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OverflowError in STalign.LDDMM
and help aligning Visium data
#30
Comments
Update: I tried the same code but with lower resolution images, and
|
Dear Nick, This tutorial for aligning Visium datasets may be useful to you: https://jef.works/blog/2023/11/05/aligning-visium-using-STalign-with-reticulate/ This tutorial also described some matrix dimensions and parameters to be careful about: https://jef.works/blog/2024/04/11/stalign-at-single-cell-resolution/ Hope this helps, |
Hello,
I'm getting the error
OverflowError: cannot convert float infinity to integer
when calling theSTalign.LDDMM()
function. I'll attach the full traceback at the bottom, but I suspect I'm likely giving bad inputs to the function, and so I'll describe a bit more how I'm attempting to useSTalign
.I'm attempting to align two Visium H&E samples that were obtained with some overlap in the XY plane but at different depths (partial overlap). I'm loading both images with
STalign.normalize(np.array(Image.open(x), dtype = np.float64) / 256)
wherex
is the path to thetissue_hires_image.png
file from Spaceranger. This is my first point of confusion, as this tutorial shows loading a Visium H&E a similar way, but I also see from this previous issue (particularly this comment) that perhapsSTalign.rasterize
should be used instead?Following along the tutorial, I manually annotate landmarks then find an initial affine transform from them, which is working well. I'm particularly interesting in getting the non-linear transform working though, and invoked
Stalign.LDDMM
just as in the tutorial:This proceeds for about an hour (using a GPU), ultimately giving the error
OverflowError: cannot convert float infinity to integer
. Here's the full traceback if it's helpful, though it looks like it's actually occurring in the plotting of the results:Thanks so much in advance! This seems like a powerful tool and I'm excited to get it working.
Best,
-Nick
The text was updated successfully, but these errors were encountered: