Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
pola-rs
GitHub Repository: pola-rs/polars
Path: blob/main/docs/source/user-guide/lazy/gpu.md
6940 views

GPU Support

Polars provides an in-memory, GPU-accelerated execution engine for the Lazy API in Python using RAPIDS cuDF on NVIDIA GPUs. This functionality is available in Open Beta, is undergoing rapid development, and is currently a single GPU implementation.

If you install Polars with the GPU feature flag, you can trigger GPU-based execution by running .collect(engine="gpu") instead of .collect().

{{ code_header("python", [], []) }}

--8<-- "python/user-guide/lazy/gpu.py:setup" result = q.collect(engine="gpu") print(result)
--8<-- "python/user-guide/lazy/gpu.py:setup" --8<-- "python/user-guide/lazy/gpu.py:simple-result"

Learn more in the GPU Support guide.