Brain atlas Module

class coperniFUS.modules.atlas.AsynchronousOnlineAtlasListRetrieval(skip_online_atlas_retreival)[source]

Bases: QThread

Handles network issues when retrieving online atlas lists.

finished

Signal emitted whenever the atlas retreival is done (or has failed).

run(self)[source]
class coperniFUS.modules.atlas.BrainAtlas(parent_viewer, skip_online_atlas_retreival=False, **kwargs)[source]

Bases: Module

BrainAtlas module.

property atlas_resolution

Resultion of the reference altas in meters (x, y, z) Suplampling is accounted for in the returned value.

property brain_atlas_tmat

Holds the atlas volume affine transformation matrix

property atlas_voxel_coordinates

Holds the coordinates of the brain atlas volume

property bg_atlas

Holds the Brain Globe instance currently loaded in the module

property available_atlases

Get a list of all (online and offline) available atlases in the dictionary form

add_reference_atlas(offline_atlas_name)[source]

Add a reference atlas to the module

remove_reference_atlas()[source]

Delete the reference atlas currently loaded in the module

add_structure_layer(structure, hemisphere)[source]

Add a brain structure layer to the atlas

remove_altas_layer(layer_name=None, tree_viewer_layer_index=None)[source]

Delete one of the currently loaded brain structure layer from the rendered atlas

property layers

Atlas layer dict, keys starting with an underscore corresponds to large data that will be omitted in the version saved in cache. Make sure than other keys contain jsonable data

General dict structure: ‘layer_name’: {‘ndimage’: data, OR ‘ndimage_from_layer_name’: ‘src_layer_name’, OR ‘atlas_structure_name’ AND ‘atlas_structure_hemisphere’}

property raw_rgba_ndimage_compound

Holds the RGBA n-dimension image of the atlas compounded layers before plane slicing operations (raw)

property rgba_ndimage_compound

Holds the RGBA n-dimension image of the atlas compounded layers with plane slicing applied

property ndimage_plane_slicing_application_mask

Holds a boolean mask indicating atlas voxels where plane silicing is ignored

property jsonable_layers_dict

Provides a copy of the layers dict omitting non-jsonable data keys (starting with an underscore) for caching purposes

update_tooltip_to_layer_centroid()[source]

Updates the Tooltip location according to the checkbox selection in the module dock

release_tooltip()[source]

Releases the tooltip location from the selected location in the module. Please call CoperniFUS viewer release_from_modules method to release the tooltip from all loaded modules.

init_dock()[source]

Called on GUI setup to add a module dock

add_rendered_object()[source]

Called when populating the viewer with the module rendered objects

update_rendered_object()[source]

Called on render view updates

delete_rendered_object()[source]

Called on deletion of the module rendered objects

get_user_param(param_name, default_value=None)[source]

Get module configuration parameter stored in cache (or default values if non existant)

set_user_param(param_name, param_value)[source]

Set module configuration parameter to cache