# Resolvi differential test does not converge (?)

**URL:** <https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907>\
**Category:** scvi-tools\
**Created:** [January 2, 2026, 8:54pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907 "2026-01-02T20:54:14Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![KSimi7](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/ksimi7/32/1560_2.png) [@KSimi7](https://discourse.scverse.org/u/KSimi7)\
**Post date:** [January 2, 2026, 8:54pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/1 "2026-01-02T20:54:14Z")

</div>

Hi,

Thanks for the great tool! I have been using Resolvi to correct for batch effects in my single cell spatial transcriptomics data. Additionally, I m also using it to check for differences between the nuclei-expanded and cellpose-segmented sample datasets. The concatenated dataset is quite large ~ 1553536 cells. After training the model, I tried computing differential expression testing on leiden clusters but even after ~2 hours compute was not done. Additionally, the progress bar shows nothing. \*In this screenshot I reran the cell after specifying group1.

Is this to be expected since the dataset is large or is there something abnormal happening? Just to mention, I don’t see a spike/change in my GPU/CPU usage after running differential test.

![image](https://canada1.discourse-cdn.com/flex035/uploads/forum11/optimized/2X/6/6768bee34967673500240f0fbcaafe00e009d144_2_690x62.png)

Thank you so much for your help!

---

<div class="post-metadata">

**Author:** ![zimmerma](https://avatars.discourse-cdn.com/v4/letter/z/51bf81/32.png) [@zimmerma](https://discourse.scverse.org/u/zimmerma)\
**Post date:** [January 6, 2026, 8:11pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/2 "2026-01-06T20:11:06Z")

</div>

I also have the same problem. Then, I ran scVIVA on the same set of cells (using the resolVI embeddings as suggested in another post) and was able to run differential expression in a much shorter amount of time.

---

<div class="post-metadata">

**Author:** ![ori-kron-wis](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/ori-kron-wis/32/1099_2.png) [@ori-kron-wis](https://discourse.scverse.org/u/ori-kron-wis)\
**Post date:** [January 7, 2026, 7:48am UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/3 "2026-01-07T07:48:08Z")

</div>

It shouldn’t be that slow, but can you verify if you run without batch\_correction=True (the default is False)

---

<div class="post-metadata">

**Author:** ![jairaj-mathur](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/jairaj-mathur/32/1188_2.png) [@jairaj-mathur](https://discourse.scverse.org/u/jairaj-mathur)\
**Post date:** [January 12, 2026, 8:31pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/4 "2026-01-12T20:31:01Z")

</div>

I have experienced the same, differential expression takes 9 hours, where as the step before, resolvi training finishes in 1.5 hours. About 300k cells x 5000 genes

---

<div class="post-metadata">

**Author:** ![jairaj-mathur](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/jairaj-mathur/32/1188_2.png) [@jairaj-mathur](https://discourse.scverse.org/u/jairaj-mathur)\
**Post date:** [January 12, 2026, 10:34pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/5 "2026-01-12T22:34:20Z")

</div>

@zimmerma Could you please elaborate on how you ran scViva on resolvi for running differential expression?

---

<div class="post-metadata">

**Author:** ![zimmerma](https://avatars.discourse-cdn.com/v4/letter/z/51bf81/32.png) [@zimmerma](https://discourse.scverse.org/u/zimmerma)\
**Post date:** [January 15, 2026, 7:36pm UTC](https://discourse.scverse.org/t/resolvi-differential-test-does-not-converge/3907/6 "2026-01-15T19:36:24Z")

</div>

Sorry for the delay. I followed the directions from this post: [ode-for-cell-annotation/3762](https://discourse.scverse.org/t/using-resolvi-s-unsupervised-mode-for-cell-annotation/3762)

What I did was run Resolvi in unsupervised mode and perform leiden clustering on the X\_resolVI embeddings to get clusters.

Then I used the X\_resolVI embeddings along with the cluster labels as input to scVIVA. From there I used the differential\_expression module scVIVA uses.
