Skip to content

Commit f9ac9d9

Browse files
STY: Apply ruff/flake8-comprehensions rule C409
C409 Unnecessary `list` literal passed to `tuple()` (rewrite as a `tuple` literal)
1 parent 00d68e6 commit f9ac9d9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

nipype/interfaces/cmtk/cmtk.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ def cmat(
248248
axis=1,
249249
)
250250
)
251-
G.nodes[int(u)]["dn_position"] = tuple([xyz[0], xyz[2], -xyz[1]])
251+
G.nodes[int(u)]["dn_position"] = (xyz[0], xyz[2], -xyz[1])
252252

253253
if intersections:
254254
iflogger.info("Filtering tractography from intersections")
@@ -1070,7 +1070,7 @@ def create_nodes(roi_file, resolution_network_file, out_filename):
10701070
np.where(np.flipud(roiData) == int(d["dn_correspondence_id"])), axis=1
10711071
)
10721072
)
1073-
G.nodes[int(u)]["dn_position"] = tuple([xyz[0], xyz[2], -xyz[1]])
1073+
G.nodes[int(u)]["dn_position"] = (xyz[0], xyz[2], -xyz[1])
10741074
with open(out_filename, 'wb') as f:
10751075
pickle.dump(G, f, pickle.HIGHEST_PROTOCOL)
10761076
return out_filename

0 commit comments

Comments
 (0)