# Scvi package can't be installed into google colab?

**URL:** <https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600>\
**Category:** scvi-tools\
**Tags:** scvi\
**Created:** [April 11, 2025, 4:11am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600 "2025-04-11T04:11:01Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jihua-Liu](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/jihua-liu/32/1350_2.png) [@Jihua-Liu](https://discourse.scverse.org/u/Jihua-Liu)\
**Post date:** [April 11, 2025, 4:11am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/1 "2025-04-11T04:11:01Z")

</div>

![image](https://canada1.discourse-cdn.com/flex035/uploads/forum11/original/2X/f/fed81e4f718c413e7f4785343036fc22aee62f61.png)  
It was working two weeks ago, but now it just doesn’t work.

---

<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:** [April 11, 2025, 4:30am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/2 "2025-04-11T04:30:03Z")

</div>

theres a temporary problem with the uv package (not scvi-tools)  
please add this line, before running the install of scvi\_colab and it will work:

```auto
#A Manual fix to uv issue in Colab, see: https://github.com/astral-sh/uv/issues/12724
import os
os.environ["UV_CONSTRAINT"] = os.environ["UV_BUILD_CONSTRAINT"] = ""

```

---

<div class="post-metadata">

**Author:** ![cane11](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/cane11/32/241_2.png) [@cane11](https://discourse.scverse.org/u/cane11)\
**Post date:** [April 11, 2025, 5:37am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/3 "2025-04-11T05:37:41Z")

</div>

Could we add this to the scVI-colab package or does it need to be called outside of it?

---

<div class="post-metadata">

**Author:** ![Jihua-Liu](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/jihua-liu/32/1350_2.png) [@Jihua-Liu](https://discourse.scverse.org/u/Jihua-Liu)\
**Post date:** [April 11, 2025, 5:49am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/4 "2025-04-11T05:49:15Z")

</div>

![image](https://canada1.discourse-cdn.com/flex035/uploads/forum11/original/2X/4/4158fb0efffe7e1bc53686f601de7eb48e42c0ce.png)  
Not exactly sure why this doesn’t work for me.

---

<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:** [April 11, 2025, 6:31am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/5 "2025-04-11T06:31:55Z")

</div>

![image](https://canada1.discourse-cdn.com/flex035/uploads/forum11/original/2X/d/daf99759a8b12292ec98177562ba472269af3ef6.png)

try it after the installation of scvi-colab, and restart your session. (I installed a specific branch here, but try it with just install())

but youre right, it is not working right now (it worked for me yesterday), I guess their on the fix, at least from what I see in the discussion of the issue [Google colab issue · Issue #12724 · astral-sh/uv · GitHub](https://github.com/astral-sh/uv/issues/12724)  
you can still install with  
`!pip install --quiet scvi-tools`

make no sense to add to the package, its not related to scvi-colab, any package will not work with uv in colab now (also numpy…) w/o the fix.

---

<div class="post-metadata">

**Author:** ![cane11](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/cane11/32/241_2.png) [@cane11](https://discourse.scverse.org/u/cane11)\
**Post date:** [April 14, 2025, 5:01am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/6 "2025-04-14T05:01:29Z")

</div>

We should then disable uv until Colab fixes it. It’s annoying but more annoying for users to first need to find this issue and then install it correctly.

---

<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:** [April 20, 2025, 7:17am UTC](https://discourse.scverse.org/t/scvi-package-cant-be-installed-into-google-colab/3600/7 "2025-04-20T07:17:49Z")

</div>

seems the issue is solved with colab/uv integraion:

 ![image](https://canada1.discourse-cdn.com/flex035/uploads/forum11/original/2X/6/6480296a452b5a6bd0378df827ef70ffc2efbb6d.png)
