ibllib.atlas.flatmaps
Module that hold techniques to project the brain volume onto 2D images for visualisation purposes
Functions
Display annotations on the flatmap |
|
|
|
Displays the 2D image corresponding to the swanson flatmap. |
|
- circles(N=5, atlas=None, display='flat')[source]
- Parameters
N – number of circles
atlas – brain atlas at 25 m
display – “flat” or “pyramid”
- Returns
2D map of indices, ap_coordinate, ml_coordinate
- plot_swanson(acronyms=None, values=None, ax=None, hemisphere=None, br=None, orientation='landscape', annotate=False, empty_color='silver', **kwargs)[source]
Displays the 2D image corresponding to the swanson flatmap. This case is different from the others in the sense that only a region maps to another regions, there is no correspondency from the spatial 3D coordinates.
- Parameters
acronyms –
values –
hemisphere – hemisphere to display, options are ‘left’, ‘right’, ‘both’ or ‘mirror’
br – ibllib.atlas.BrainRegions object
ax – matplotlib axis object to plot onto
orientation – ‘landscape’ (default) or ‘portrait’
annotate – (False) if True, labels regions with acronyms
empty_color – (grey) matplotlib color code or rgb_a int8 tuple defining the filling of brain regions not provided. Defaults to ‘silver’
kwargs – arguments for imshow
- Returns
- annotate_swanson(ax, acronyms=None, orientation='landscape', br=None, **kwargs)[source]
Display annotations on the flatmap
- Parameters
ax –
acronyms – (None) list or np.array of acronyms or allen region ids. If None plot all.
orientation –
br – BrainRegions object
kwargs – arguments for the annotate function
- Returns