Skip to content

Commit

Permalink
[FIX] IXI-to-BIDS function define_participants should output sorted…
Browse files Browse the repository at this point in the history
… participants list (#1318)
  • Loading branch information
AliceJoubert authored Oct 9, 2024
1 parent 45d02d7 commit 9ed92e5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clinica/iotools/converters/ixi_to_bids/ixi_to_bids_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def define_participants(

list_from_data = _get_subjects_list_from_data(data_directory)
if subjs_list_path is None:
return list_from_data
return sorted(list_from_data)
cprint("Loading a subjects list provided by the user...")
list_from_file = _get_subjects_list_from_file(subjs_list_path)
list_filtered = [subject for subject in list_from_file if subject in list_from_data]
Expand All @@ -77,7 +77,7 @@ def define_participants(
f"The subjects : {' , '.join(invalid_subjects)} do not have any associated data inside the directory {data_directory}"
f" and can not be converted."
)
return list_filtered
return sorted(list_filtered)


def _rename_clinical_data_to_bids(column: str) -> str:
Expand Down

0 comments on commit 9ed92e5

Please sign in to comment.