def main():
    # Extract the tracts from the atlas' folder
    tracts = get_tracts(folder_atlas)
    nb_tracts = len(tracts)
    # Get the sum of the tracts
    tracts_sum = add_tracts(tracts, tracts_to_sum_index)
    # Save sum of the tracts to niftii
    save_3D_nparray_nifti(tracts_sum, 'tmp.WM_all.nii.gz', folder_atlas+'/WMtract__00.nii.gz')
    # binarize it
    sct.run('fslmaths tmp.WM_all.nii.gz  -thr 0.5 -bin tmp.WM_all_bin.nii.gz')
    # dilate it
    sct.run('fslmaths tmp.WM_all_bin.nii.gz  -kernel boxv 5x5x1 -dilM tmp.WM_all_bin_dil.nii.gz')
    # subtract WM mask to obtain CSF mask
    sct.run('fslmaths tmp.WM_all_bin_dil -sub tmp.WM_all '+folder_atlas+'/'+file_csf)
    # add line in info_label.txt
    text_label = '\n'+str(nb_tracts)+', CSF, '+file_csf
    open(folder_atlas+'/'-file_label, 'a+b').write(text_label)
dataset/ETHPy150Open neuropoly/spinalcordtoolbox/dev/atlas/create_atlas/create_masks_csf_and_gm.py/main/operator `+` -> `-`