marimo notebooks on molab#
molab is a free hosted service for running marimo notebooks in the cloud. You can attach an NVIDIA RTX Pro 6000 (Blackwell) GPU to any molab notebook from the notebook editor. See the molab documentation for the current GPU options and usage limits.
Create a GPU notebook#
Sign in to molab and select Create a notebook.
Select the resources button in the notebook header, which shows 4 CPU · 32 GiB. Under GPUs, select RTX Pro 6000 (Blackwell), then select Save and restart.
Install the libraries#
The %pip magic doesn’t work in marimo notebooks. Install the libraries from
the Packages panel instead.
Select the cube icon in the sidebar to open the Packages panel.
Paste the following line into the package input and select Add.
--extra-index-url=https://pypi.anaconda.org/rapidsai-wheels-nightly/simple cudf-cu13==26.12.*,>=0.0.0a0 cuml-cu13==26.12.*,>=0.0.0a0
molab shows the installation logs in an Installing packages dialog. Wait for the installation to finish.
Restart the kernel to ensure Python recognizes the newly installed libraries. Select the menu icon in the top right of the notebook, then select Restart kernel.
Without a restart,
import cudffails withModuleNotFoundError: No module named 'numba.cuda.core'.
This installs cuDF and cuML. To install other NVIDIA CUDA-X libraries for data science, find their package names in the release selector and add them to the line without the quotes, separated by spaces.
Verify the installation#
Enter the following code in a notebook cell and run it:
import cudf
import cuml
gdf = cudf.DataFrame({"a": [1, 2, 3], "b": [4, 5, 6]})
print(gdf.sum())
The cell should produce the following output:
a 6
b 15
dtype: int64
This confirms that cuDF and cuML can use the GPU. If the cell fails, check that the GPU is turned on and that you restarted the kernel after installing.
To get started with cuDF, work through 10 Minutes to cuDF.