Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-b-miller committed Nov 2, 2023
1 parent f4bcdc2 commit e04ca18
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions python/cugraph/cugraph/structure/graph_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,7 @@ def from_numpy_array(self, np_array, nodes=None):
nodes: array-like or None, optional (default=None)
A list of column names, acting as labels for nodes
"""
if not isinstance(np_array, np.ndarray):
raise TypeError("np_array input is not a Numpy array")
np_array = np.asarray(np_array)
if len(np_array.shape) != 2:
raise ValueError("np_array is not a 2D matrix")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1288,7 +1288,7 @@ def nodes(self):
else:
return cudf.concat(
[df[simpleGraphImpl.srcCol], df[simpleGraphImpl.dstCol]]
).unique()
).drop_duplicates()
if self.adjlist is not None:
return cudf.Series(np.arange(0, self.number_of_nodes()))

Expand Down

0 comments on commit e04ca18

Please sign in to comment.