conpy.select_vertices_in_sensor_range#
- conpy.select_vertices_in_sensor_range(inst, dist, info=None, picks=None, trans=None, indices=False, verbose=None)[source]#
Find vertices within given distance to a sensor.
- Parameters:
- instinstance of Forward | instance of SourceSpaces
The object to select vertices from.
- distfloat
The minimum distance between a vertex and the nearest sensor. All vertices for which the distance to the nearest sensor exceeds this limit are discarded.
- infoinstance of Info | None
The info structure that contains information about the channels. Only needs to be specified if the object to select vertices from does is an instance of SourceSpaces.
- picksarray-like of int | None
Indices of sensors to include in the search for the nearest sensor. If
None
, the default, only MEG channels are used.- transstr | instance of Transform | None
Either the full path to the head<->MRI transform
*-trans.fif
file produced during coregistration, or the Transformation itself. If trans is None, an identity matrix is assumed. Only needed wheninst
is a source space in MRI coordinates.- indices: False | True
If
True
, return vertex indices instead of vertex numbers. Defaults toFalse
.- verbosebool | str | int | None
If not None, override default verbose level (see
mne.verbose()
and Logging documentation for more).
- Returns:
- verticespair of lists | list of int
Either a list of vertex numbers for the left and right hemisphere (if
indices==False
) or a single list with vertex indices.
See also
restrict_forward_to_vertices
restrict Forward to the given vertices
restrict_src_to_vertices
restrict SourceSpaces to the given vertices