@@ -19,14 +19,13 @@ from cuda.core._resource_handles cimport (
1919 as_intptr,
2020 as_py,
2121 create_graph_handle,
22- create_graph_handle_ref,
2322 create_graph_node_handle,
2423)
2524from cuda.core._utils.cuda_utils cimport HANDLE_RETURN
2625
2726from dataclasses import dataclass
2827
29- from cuda.core._utils.cuda_utils import driver, handle_return
28+ from cuda.core._utils.cuda_utils import driver
3029
3130
3231cdef class Condition:
@@ -347,7 +346,7 @@ cdef class GraphDef:
347346 with nogil:
348347 HANDLE_RETURN(cydriver.cuGraphGetNodes(as_cu(self._h_graph), nodes_vec.data(), &num_nodes))
349348
350- return set( GraphNode._create(self._h_graph, nodes_vec[i]) for i in range(num_nodes))
349+ return { GraphNode._create(self._h_graph, nodes_vec[i]) for i in range(num_nodes)}
351350
352351 def edges(self) -> set:
353352 """ Return all edges in the graph as (from_node, to_node) pairs.
@@ -386,11 +385,11 @@ cdef class GraphDef:
386385 HANDLE_RETURN(cydriver.cuGraphGetEdges(
387386 as_cu(self._h_graph), from_nodes.data(), to_nodes.data(), &num_edges))
388387
389- return set(
388+ return {
390389 (GraphNode._create(self._h_graph, from_nodes[i]),
391390 GraphNode._create(self._h_graph, to_nodes[i]))
392391 for i in range(num_edges)
393- )
392+ }
394393
395394 @property
396395 def handle(self) -> driver.CUgraph:
0 commit comments