Skip to content

Commit

Permalink
FIX: pep8
Browse files Browse the repository at this point in the history
  • Loading branch information
AntoineTheb committed Dec 26, 2024
1 parent 1132b4a commit 4bf9d51
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scilpy/tractograms/dps_and_dpp_management.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# -*- coding: utf-8 -*-
import numpy as np

from collections.abc import Iterable
from nibabel.streamlines import ArraySequence


Expand Down Expand Up @@ -40,9 +39,10 @@ def get_data_as_arraysequence(data, ref_sft):

elif data.shape[0] == ref_sft._get_point_count():
# Split the data into a list of arrays, one per streamline.
# np.split takes the indices at which to split the array, so use
# np.split takes the indices at which to split the array, so use
# np.cumsum to get the indices of the end of each streamline.
data_split = np.split(data, np.cumsum(ref_sft.streamlines._lengths)[:-1])
data_split = np.split(
data, np.cumsum(ref_sft.streamlines._lengths)[:-1])
# Create an ArraySequence from the list of arrays.
data_as_arraysequence = ArraySequence(data_split)
else:
Expand Down

0 comments on commit 4bf9d51

Please sign in to comment.