Skip to content

Commit

Permalink
Update for networkx version 3 SCMSUITE-10090 SO107
Browse files Browse the repository at this point in the history
  • Loading branch information
dormrod committed Nov 19, 2024
1 parent 7fb4b40 commit e48be41
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mol/identify.py
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ def get_graph(mol, dic, level=1):
matrix *= identifiers.reshape((nats, 1))

# Create the graph
graph = networkx.from_numpy_matrix(matrix)
graph = networkx.from_numpy_array(matrix)

return graph

Expand Down
2 changes: 1 addition & 1 deletion mol/molecule.py
Original file line number Diff line number Diff line change
Expand Up @@ -1570,7 +1570,7 @@ def locate_rings_networkx(self):
matrix = self.bond_matrix()
matrix = matrix.astype(np.int32)
matrix[matrix > 0] = 1
graph = networkx.from_numpy_matrix(matrix)
graph = networkx.from_numpy_array(matrix)
rings = networkx.cycle_basis(graph)
return rings

Expand Down

0 comments on commit e48be41

Please sign in to comment.