

def add_tracts(tracts, tracts_to_sum_index):
    tracts_sum = np.empty(tracts[(0, 0)].shape)
    for i in tracts_to_sum_index:
        tracts_sum = (tracts_sum + tracts[(i, 0)])
    return tracts_sum

dataset/ETHPy150Open neuropoly/spinalcordtoolbox/dev/atlas/create_atlas/create_masks_csf_and_gm.py add_tracts/original