if not doJif:
if len(label_list) != len(atlas_list):
raise ValueError("len(label_list) != len(atlas_list)")
inlabs = np.sort(np.unique(label_list[0][target_image_mask != 0]))
mymask = target_image_mask.clone()
else:
mymask = target_image_mask
After Change
if not doJif:
if len(label_list) != len(atlas_list):
raise ValueError("len(label_list) != len(atlas_list)")
if no_zeroes:
for label in label_list:
target_image_mask[label == 0] = 0
inlabs = set()
for label in label_list:
values = np.unique(label[target_image_mask != 0 and label != 0])
inlabs = inlabs.union(values)