Query-engine that maps center nodes to indices of features (voxels) that are near each center node.
In a typical use case such an instance is generated using the function ‘disc_surface_queryengine’
This class is for mappings from surface to voxel features; for mappings from surface to surface features, use SurfaceQueryEngine.
Methods
feature_id2linear_voxel_ids(feature_id) | |
feature_id2nearest_vertex_id(feature_id[, ...]) | Compute the index of the vertex nearest to a given voxel. |
get_masked_nifti_image([center_ids]) | Return a NIfTI image binary mask with voxels covered by searchlights |
linear_voxel_id2feature_id(linear_voxel_id) | |
query(**kwargs) | |
query_byid(vertexid) | Given a vertex ID give us indices of dataset features (voxels) |
train(dataset) | Train the query engine on a dataset |
untrain() | |
vertex_id2nearest_feature_id(vertex_id) | Compute the index of the voxel nearest to a given vertex. |
Makes a new SurfaceVerticesQueryEngine
Parameters : | voxsel: volume_mask_dict.VolumeMaskDictionary :
space: str (default: ‘voxel_indices’) :
add_fa: list of str :
|
---|
Methods
feature_id2linear_voxel_ids(feature_id) | |
feature_id2nearest_vertex_id(feature_id[, ...]) | Compute the index of the vertex nearest to a given voxel. |
get_masked_nifti_image([center_ids]) | Return a NIfTI image binary mask with voxels covered by searchlights |
linear_voxel_id2feature_id(linear_voxel_id) | |
query(**kwargs) | |
query_byid(vertexid) | Given a vertex ID give us indices of dataset features (voxels) |
train(dataset) | Train the query engine on a dataset |
untrain() | |
vertex_id2nearest_feature_id(vertex_id) | Compute the index of the voxel nearest to a given vertex. |
Compute the index of the vertex nearest to a given voxel.
Parameters : | feature_id: int :
fallback_euclidean_distance: bool (default: False) :
|
---|---|
Returns : | vertex_id: int :
|
Return a NIfTI image binary mask with voxels covered by searchlights
Parameters : | center_ids: list or None :
|
---|---|
Returns : | img: nibabel.Nifti1Image :
|
Notes
When using surface-based searchlights, a use case of this function is to get the voxels that were associated with the searchlights in a subset of all nodes on a cortical surface.
Given a vertex ID give us indices of dataset features (voxels)
Parameters : | vertexid: int :
|
---|---|
Returns : | voxel_ids: list of int or AttrDataset :
|
Train the query engine on a dataset
Compute the index of the voxel nearest to a given vertex.
Parameters : | vertex_id: int :
|
---|---|
Returns : | feature_id: int :
|
Notes
This function only considers feature ids that are selected by at least one vertex_id..