Expand description
Workspace-internal safe libcugraph execution component for Algeon.
Published as an Algeon implementation dependency. Applications use
algeon-datafusion; workspace code
uses this crate for its component contracts. See the
API documentation boundary.
Algeon integrations enter through a runtime-bound ResourceHandle, use
the prepared transfer contracts in cudf_interop, and retain explicit
producer readiness and consumer completion ordering. Native failures are
preserved as structured Error values.
§Key concepts
cudf_interop: canonical prepared cuDF graph ingress and result egress for the Algeon engine.ResourceHandle: long-lived owner of GPU execution provenance (bound device, retained runtime, cuGraph resource handle). Not thread-safe.EnteredContext: short-lived execution session created byResourceHandle::enter. GPU-capable APIs require this token.DeviceArray<T>: owning GPU array with compile-time element type. Freed on drop. Create views viaDeviceArray::view().GraphBuilder: low-level builder for constructing aGraphfrom pre-materialized device edge lists. Validates inputs before crossing the FFI boundary.Graph<T>: graph container parameterized by transposition state (ForwardorTransposed). Algorithm methods are constrained by the required layout.
§Type-state encoding
The Graph<T> type parameter encodes whether storage is in forward or
transposed layout. Algorithms enforce their required layout at compile time:
Forward: required byGraph::bfsandGraph::louvainTransposed: required byGraph::pagerank,Graph::in_degrees,Graph::degrees- Generic (
T: Transposition):Graph::betweenness_centrality,Graph::force_atlas2,Graph::out_degrees
§cudf interop
The cudf_interop module owns single-GPU prepared graph construction
from cudf tables and result-to-DataFrame conversion. The prepared export
contract is the canonical Algeon ingress path.
Re-exports§
pub use array::DeviceArray;pub use array::DeviceArrayView;pub use error::AllocationFailureSource;pub use error::AllocationSource;pub use error::Error;pub use error::ErrorKind;pub use error::ErrorStatus;pub use graph::Forward;pub use graph::Graph;pub use graph::GraphBuilder;pub use graph::ParkedGraph;pub use graph::Transposed;pub use graph::Transposition;pub use handle::EnteredContext;pub use handle::ResourceHandle;pub use structure::VertexSelection;
Modules§
- array
- Typed device and host array views over cuGraph allocations.
- centrality
- Centrality algorithms (PageRank, betweenness centrality, etc.).
- community
- Community-detection algorithms.
- cudf_
interop - Canonical cuDF interoperability for the Algeon cuGraph backend.
- error
- Errors carry a
ErrorKindvariant, anErrorStatusrecording the observed source condition, an operation name describing what was being attempted, an optional human-readable message, optional key-value context pairs, and an optional source error. This makes it easy to diagnose failures without losing the underlying cause. The status is the observation and does not grant permission to retry. Callers decide recovery only after cleanup and device-health checks. - graph
- Graph construction and management.
- handle
- GPU resource handle for cuGraph operations.
- labeling
- Vertex labeling algorithms.
- layout
- Layout algorithms (Force Atlas 2, etc.).
- params
- Strongly-typed parameter wrappers for cuGraph algorithm configuration.
- random
- Random number generator state for cuGraph algorithms.
- sampling
- Random-walk and sampling algorithms.
- similarity
- Similarity algorithms and the owned vertex-pair collection (
VertexPairs). - structure
- Graph structure queries (degrees, core numbers, etc.).
- traversal
- Graph traversal algorithms.
- tree
- Tree algorithms.
- types
- Fundamental types shared across the cuGraph Rust API.