Below I've copied the important parts of how to resolve the issues/questions posted here. All credit for an answer to this question goes to the developer of BrainRender(FedeClaudi on GitHub). I am copying the key information he provide my team in case the following link to the developers answer stops working: https://github.com/BrancoLab/BrainRender/issues/70
The developer of the BrainRender tool updated this tool to version 0.4.0.0 which allows users to permanently add labels to brain areas:
pip install -U brainrender
You should also update using:
https://github.com/BrancoLab/BrainRender.git
Some key things to know about how the labels work:
Labels appear on the right hemisphere by default
added xoffset
, yoffset
and zoffset
to manually alter the location of the label
added a colored sphere to the point on the mesh that corresponds to the label location [optional]
This is how we resolved our brain loading upside down, it turns out this is just an issue that occurs with Jupyter notebook:
from vtkplotter import embedWindow
from brainrender.scene import Scene
# Change 1 Disable scene embedding with k3d in vtkplotter
embedWindow(False)
# Change 2 set jupyter to False when creating the scene
scene = Scene(jupyter=False)
# Populate and render
scene.add_brain_regions(['MOp', 'MOs', 'VISl', 'VISp', 'RSPagl'], add_labels=True)
scene.add_text('title')
scene.render(camera='top')
The developer also warned "to avoid import vtkplotter as vtk
because there's another package called vtk
".