How would I translate an MRI coordinate, lets say (x=33, y=8, z=57) to the
nearest source point (="vertex") in the source space? Could someone explain a
bit about the coordinate systems and transforms in play?
MNE uses "Freesurfer surface RAS" coordinates for the source space, so make
sure your points are in that coordinate frame in meters. So if they x/y/z
you gave were in surface RAS mm, divide by 1000. If they were voxel
numbers, you could use img.header.vox2ras_tkr after loading your img with
nibabel.load, then divide by 1000 (since Nibabel uses mm units).
Once your points are in meters in Freesurfer surface RAS coordinate system,
you can just brute force the nearest calculation using some suitable
nearest-point algorithm (scipy's KDTree, sklearn's BallTree, or just
scipy.spatial.distance.cdist plus argmin) to the `src[0]['rr']` points.