Skip to content

Use case: tracing electrode tracks

Rob Campbell edited this page Jun 26, 2019 · 17 revisions

You can trace electrode tracks in Lasagna with Plugins > Annotation plugins > Add line plugin. On an Apple laptop you will need an external mouse. Please report any crashes or other issues with this procedure.

Steps

Load image stacks

  • Load the image stacks with File > Load ingredient > New image stack. The whole stack is loaded into RAM. During loading the GUI is unresponsive. Just wait and it will load.
  • You may load multiple channels and they will be automatically overlaid in different colours.
  • If you see nothing when the images are loaded, just change the look-up table by dragging the slider box in the histogram.
  • Lasagna assumes samples are isotropic. Say your data were acquired at 5x5x20 microns. To get square images you should go to the Axis tab and set "View 2" to 4 and "View 3" to 0.25

Starting the plugin

  • Start the plugin: Plugins > annotation_plugins > add_line_plugin
  • Click on the "Points" tab.
  • Select "Piecewise" from the drop-down selector box under Add/Remove.

Exploring the stack

Scan through the stack to get a feel for where the track is. Following the instructions in Navigating data to pan, zoom, and slice the data. Note that with the plugin started, a left-click will add a point but you can still click and drag without adding a point. The autofluoresence may well look grainy, but the tracks should be bright.

Tracing a track

  • If you have multiple tracks, name your first track in the GUI.
  • Use left-click to place the first point at the brain surface where the electrode entered. You may click on any of the axes, but the coronal plane may be easiest.
  • Continue scrolling through the brain and adding points. New points are appended to the end of the line.
  • You can extend the range of depths over which the line and points are visible by altering the "z-spread" values. Separate values for each axis. Likely you will want quite large Z-spread numbers for the non-coronal views as the program currently uses distance to the nearest clicked point to decide what to show.
  • You change the colour of the points or lines by clicking on the "ingredient" in the list (the points are called "addLine_currentLine") then changing the color, line width, etc, with the options below. The line is "addLine_fit_currentLine. We are aware this is naming system is not intuitive.

Modifying the track

  • If you make a mistake, you can delete a point by selecting the ""Remove" radio button. The highlighted point nearest the mouse will be removed when you right-click. Return to "Add" mode when done.
  • You may go back an insert points between others by right-clicking on a point. It now becomes highlighted. You can highlight a different point, again with a right-click, if needed. You may cancel insert mode by right-clicking again near the highlighted point. The next point you add by left-clicking will be added between the highlighted point and the one before it.

Committing the track

Once you are happy with the track hit "Add it!" in the add_line_plugin GUI. The points and fit will change colour and be named according to the name you previously entered in the plugin window. Save the track by right-clicking on the ingredient containing the string _pts. The plugin is new and might crash: save tracks once created. To a new line, enter a new name in the plugin GUI and start clicking on a new track.

Re-loading data

You can currently re-load data via the main Lasagna GUI by doing File > Load ingredient > Sparse Point Read. This shows the clicked points not the line. Currently there is no option to show the data in line form.