Skip to content

Commit 77a42aa

Browse files
authored
Update installation instructions for cuML with BERTopic. (#2446)
1 parent 924a9ed commit 77a42aa

File tree

3 files changed

+48
-15
lines changed

3 files changed

+48
-15
lines changed

docs/getting_started/clustering/clustering.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,23 @@ The great thing about using cuML's HDBSCAN implementation is that it supports ma
110110
However, it is still possible to calculate the topic-document probability matrix for the data on which the model was trained (i.e., `.fit` and `.fit_transform`).
111111

112112
!!! note
113-
If you want to install cuML together with BERTopic using Google Colab, you can run the following code:
113+
To install cuML with BERTopic, run these commands:
114114

115+
**For CUDA 12:**
115116
```bash
117+
!pip install cuml-cu12
116118
!pip install bertopic
117-
!pip install cudf-cu11 dask-cudf-cu11 --extra-index-url=https://pypi.nvidia.com
118-
!pip install cuml-cu11 --extra-index-url=https://pypi.nvidia.com
119-
!pip install cugraph-cu11 --extra-index-url=https://pypi.nvidia.com
120-
!pip install --upgrade cupy-cuda11x -f https://pip.cupy.dev/aarch64
121119
```
120+
121+
**For CUDA 13:**
122+
```bash
123+
!pip install cuml-cu13
124+
!pip install bertopic
125+
```
126+
127+
!!! warning
128+
Install cuML first, then BERTopic. Installing both in a single command can fail due to pip resolver limitations with CUDA runtime dependencies.
129+
130+
**Note:** cuML is already installed on Google Colab.
131+
132+
For more detailed information on installing cuML, including additional dependencies and platform-specific instructions, see the [RAPIDS installation guide](https://docs.rapids.ai/install/).

docs/getting_started/dim_reduction/dim_reduction.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -97,16 +97,27 @@ topic_model = BERTopic(umap_model=umap_model)
9797
```
9898

9999
!!! note
100-
If you want to install cuML together with BERTopic using Google Colab, you can run the following code:
100+
To install cuML with BERTopic, run these commands:
101101

102+
**For CUDA 12:**
102103
```bash
104+
!pip install cuml-cu12
103105
!pip install bertopic
104-
!pip install cudf-cu11 dask-cudf-cu11 --extra-index-url=https://pypi.nvidia.com
105-
!pip install cuml-cu11 --extra-index-url=https://pypi.nvidia.com
106-
!pip install cugraph-cu11 --extra-index-url=https://pypi.nvidia.com
107-
!pip install --upgrade cupy-cuda11x -f https://pip.cupy.dev/aarch64
108106
```
109107

108+
**For CUDA 13:**
109+
```bash
110+
!pip install cuml-cu13
111+
!pip install bertopic
112+
```
113+
114+
!!! warning
115+
Install cuML first, then BERTopic. Installing both in a single command can fail due to pip resolver limitations with CUDA runtime dependencies.
116+
117+
**Note:** cuML is already installed on Google Colab.
118+
119+
For more detailed information on installing cuML, including additional dependencies and platform-specific instructions, see the [RAPIDS installation guide](https://docs.rapids.ai/install/).
120+
110121

111122
## **Skip dimensionality reduction**
112123
Although BERTopic applies dimensionality reduction as a default in its pipeline, this is a step that you might want to skip. We generate an "empty" model that simply returns the data pass it to:

docs/getting_started/tips_and_tricks/tips_and_tricks.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -181,16 +181,27 @@ embeddings = normalize(embeddings)
181181
However, it is still possible to calculate the topic-document probability matrix for the data on which the model was trained (i.e., `.fit` and `.fit_transform`).
182182

183183
!!! note
184-
If you want to install cuML together with BERTopic using Google Colab, you can run the following code:
184+
To install cuML with BERTopic, run these commands:
185185

186+
**For CUDA 12:**
186187
```bash
188+
!pip install cuml-cu12
187189
!pip install bertopic
188-
!pip install cudf-cu11 dask-cudf-cu11 --extra-index-url=https://pypi.nvidia.com
189-
!pip install cuml-cu11 --extra-index-url=https://pypi.nvidia.com
190-
!pip install cugraph-cu11 --extra-index-url=https://pypi.nvidia.com
191-
!pip install --upgrade cupy-cuda11x -f https://pip.cupy.dev/aarch64
192190
```
193191

192+
**For CUDA 13:**
193+
```bash
194+
!pip install cuml-cu13
195+
!pip install bertopic
196+
```
197+
198+
!!! warning
199+
Install cuML first, then BERTopic. Installing both in a single command can fail due to pip resolver limitations with CUDA runtime dependencies.
200+
201+
**Note:** cuML is already installed on Google Colab.
202+
203+
For more detailed information on installing cuML, including additional dependencies and platform-specific instructions, see the [RAPIDS installation guide](https://docs.rapids.ai/install/).
204+
194205

195206
## **Lightweight installation**
196207

0 commit comments

Comments
 (0)