Package: brainrender-test
BrainRenderbrainrenderis a python package for the visualization of three dimensional anatomical data from mice brains registered to the Common Coordinate Framework (CCF) from the Allen Institute.
Please check theuser guideand theexamplesnotebooks for more information on how to use BrainRender.For more information aboutbrainrenderand how to use it, checkout thebrainrender preprint.InstallationTo installbrainrender, use an existing python environment or create one [withpython < 3.8] and install with:pip install brainrenderDescriptionbrainrendercan be used to download and visualize anatomical data from publicly available datasets as well as user generated content. Data from the Allen Mouse Brain Atlas and Allen Mouse Connectome projects can be used to visualise the three dimensional morphology of brain region and obtain a qualitative understanding of the I/O connective of a region of interest.
Brainrender can also be used to visualise reconstructed neuronal morphologies, either by downloading them directly from MouseLight project from Janelia Research campus, or by rendering reconstructions obtained from elsewhere (e.g. fromneuromorpho.org).In addition,brainrendercan be used to visualise data generated within your lab. Brainrender can be used to visualise the results of tracing experiments (e.g. location of the injection site and labelled cells) and to visualise the location of chronically implanted device (such as electrodes arrays or optic fibres).Publicly available datasetsAllen Mouse Brain AtlasAnatomical and projection data is downloaded from the  Allen Brain Atlasreference atlasandconnectivity atlasusing the AllenAPI(© 2015 Allen Institute for Brain Science. Allen Brain Atlas API. Available from:brain-map.org/api/index.html) ([1], [2]).Brain structuresBrain structures are the most fundamental element of anybrainrenderscene. You can use brainrender to select which brain regions you'd like to visualise, and how they should look (color, transparency...). Brainrender then takes care of downloading and rendering the 3D mesh for the selected regions.StreamlinesEfferent anatomical projections  from a region of interest as determined by local injections of an anterogradely transported virus (seeAllen's connectivity atlas) can be rendered as 'streamlines'.Streamlines reconstructions are made byhttps://neuroinformatics.nlusing the mouse connectome data from Allen (seeherefor more details).
Brainrender automatically downloads and renders streamlines data for a brain region of interest.Brain structuresAfferent projectionsEfferent projectionsMouseLight neuronsAfferent projectionsThe same data used to extract information about efferent projections, can be visualised in an alternative way to look at afferent projections to a region of interest. Inbrainrenderthis type of data visualisation is called tractography.
Brainrender can be used to select the subset of experiment (injection of an anterograde virus expressing a fluorescent marker) which resulted in fluorescence in the region of interest from the >1000 experiments in the Allen Mouse Connectome project.
The location of virus injection and the projection from that location to the region of itnerest is then displayed.Mouselight and neurons morphologyTo look at the morphology of single neurons in the mouse brain,brainrendercan be used to download and render single
neurons morphological data from Janelia'smouse lightdatabase
(see theneurons browser). [3]
These reconstructions are aligned to the Allen brain atlas, so the neurons morphology can be visualised along other types of data (e.g. efferent/afferent projections) inbrainrender.Brainrender can be used to visualise neuronal morphologies from other sources by loading.swcfiles directly.
Additionally,brainrendercan also be used to download morphologies from the Allen Cell Types project.
A large number of neuronal morphologies can be found atneuromorpho.org.User generated contentBrainrender can be used to visualise data generated within individual labs, such as the results of a tracing experiments.Injection siteLabelled neuronsThis often requires that the raw data be registered to the Allen atlas, before being visualised in brainrender.
This functionality is not supported inbrainrender, however brainrender can be used to visualise data registered with other packages such asamap(github repo) andcellfinder(github repo).You can also usebrainrenderto visualise the position of devices implanted in the brain (e.g. optic cannula).
At the moment this can only be done by rendering colored cylinders at the location where the implant is, but we're happy to add more functionality, get in touch if you need anything specific!Optic fibreElectrodes arrayMaking figuresBrainrender's high quality renderings can be exported as.pngimages directly within brainrender, facilitating the creation of figure for scientific talks and publications.MouseLight neuronLabelled cellsBrainrender can also be used to create videos and animations. At the moment this functionality is not well supported, if you need to do something that brainrender can't yet do, please get in touch!Behind the scenesBrainrender was deisgned to be a powerful and flexible software for downloading and rendering neuroanatomical data while still being relatively easy to use (using brainrender requires minimal coding experience).
This was achieved by:handling the interaction with the API, SDK and databases services used to find and download the data behind the scenes, requiring minimal user input.Usingvtkplotterto handle the rendering. Vtkplotter  (github repo) is a powerful rendering engine that produces high quality three dimensional rendering. Vtkplotter is also flexible, meaning that it can handle data provided in various file formats, allowingbrainrenderto render data from various sources.Getting in touchIf you're unsure how to usebrainrender, please start by having a look at theuser guideand theexamplesnotebooks. If you still have unanswered questions, please do not hesitate to get in touch (the easiest way is to open an issue on github).For any bug report or feature request, please open an issue with a brief description of the matter.
Although brainrender can already to much, we are always happy to add more functionality that could be useful for users. If you spot some feature that is missing, we'd love to hear about is so please get in touch!Referencing Brain RenderIf you found BrainRender useful and decided to include a rendering in your talks, posters or article, please acknowledge BrainRender's contribution by citing thebrainrender preprintas:Brainrender. A python based software for visualisation of neuroanatomical and morphological data.
Federico Claudi, Adam L. Tyson, Tiago Branco
bioRxiv 2020.02.23.961748; doi: https://doi.org/10.1101/2020.02.23.961748Similar toolsIn Rcocoframeris an R library for interacting with the Allen's Mouse CCFgithub repository.mouselightrpackage generates 3D CCF mouse brain plots, along with MouseLight neuron reconstructionsgithub repositoryReferences[1] Lein, E.S. et al. (2007) Genome-wide atlas of gene expression in the adult mouse brain, Nature 445: 168-176. doi:10.1038/nature05453[2] Oh, S.W. et al. (2014) A mesoscale connectome of the mouse brain, Nature 508: 207-214. doi:10.1038/nature13186[3]  Winnubst, J. et al. (2019) Reconstruction of 1,000 Projection Neurons Reveals New Cell Types and Organization of Long-Range Connectivity in the Mouse Brain, Cell 179: 268-281