megicparc.functions
.compute_anatomical_mask¶
- megicparc.functions.compute_anatomical_mask(labels, src, constr_out=True)¶
Define anatomical constraints d_ij^a
Parameters:¶
- labelslist of Label
Anatomical region used as reference
- srcSourceSpaces
Source space to be parcellated
- constr_outbool
Wheter or not use anatomical constraints also on outliers (*).
Reutrns:¶
- anat_maskndarray of float, shape (n_sources, n_sources)
Distance matrix defining the anatomical constrains
Notes.¶
- d_ij^a = 0 if vi and vj are in the same anatomical region
or they are both outlier within the same hemi (*)
d_ij^a = 1 otherwise