Skip to content

Commit 176cff0

Browse files
Use set instead of np.unique to avoid sorting
- Also avoids casting the list to np.array
1 parent e2a996e commit 176cff0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

nipype/pipeline/engine/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -753,7 +753,7 @@ def _merge_graphs(
753753
# nodes of the supergraph.
754754
supernodes = supergraph.nodes()
755755
ids = [n._hierarchy + n._id for n in supernodes]
756-
if len(np.unique(ids)) != len(ids):
756+
if len(set(ids)) != len(ids):
757757
# This should trap the problem of miswiring when multiple iterables are
758758
# used at the same level. The use of the template below for naming
759759
# updates to nodes is the general solution.

0 commit comments

Comments
 (0)