Skip to content
Snippets Groups Projects
Commit 26cd5e5f authored by Johannes Stelzer's avatar Johannes Stelzer
Browse files

readme half written...

parent 12b52709
No related branches found
No related tags found
No related merge requests found
# Prerequisite software
A list of python libraries are needed for vviewer to function.
You can install them by
pip install -r requirements.txt
# Setup For Ubuntu 14.04
If you want to start the vviewer directly from the terminal, you will have to edit your ~/.bashrc file, adding this line:
export PATH=<directory>:$PATH
substituting <directory> with the vviewer/vviewer directory (the one that containts vviewer.py).
Then you can launch the viewer as:
vviewer.py -in bla.nii -z overlay.nii
## Setup For Mac
If you don't have pip on your mac, you can install it following these instructions:
https://ahmadawais.com/install-pip-macos-os-x-python/
Alternatively you can use homebrew, macport or get-pip.py from pip's home page.
# vviewer
A python visualization utility for MR imaging of 3D slices.
Vviewer is a light-weight viewer for MR data. Currently, we support .nii, .nii.gz, .img/.hdr and .v (lipsia's vista format). The viewer is written in python and does not have any external dependencies.
## Prerequisite software
A list of libraries needed for vviewer to function properly are listed below.
* numpy
* scipy
* nibabel
You can find the installation ...
## Setup For Ubuntu 14.04
Run
#Usage
$ sudo apt-get install python-pip
## Open an image
You can open images directly from the terminal, using
$ sudo pip install numpy scipy nibabel
vviewer.py -in data.nii
The LD_LIBRARY_PATH has to be set to the pyvista library. To do this run
$ export LD_LIBRARY_PATH="Path to directory"/vviewer/vviewer/pyvista/lib/
in the terminal that you want to run the viewer in.
For the installation.
Alternatively, you can click in the menu on file / open image.
If you want to start the vviewer directly from the terminal, you will have to edit your ~/.bashrc file, adding this line:
export PATH=<directory>:$PATH
## Clicking and slicing
The viewer shows three panes: coronal, saggital and axial. You can click and drag into any of the panes to navigate within the given plane. You can use the arrow keys on your keyboard to navigate in a voxel-by-voxel fashion (the green crosshair indicates the active pane).
In order to zoom into the image, use your mouse wheel or "," and "." on your keyboard.
If you want to shift the image left, right, up or down, hold the mouse wheel button while moving.
The voxel's current location is displayed in the ???, in voxel coordinates. If you want to switch to millimetres/MNI coordinates, click on the button???. The intensity value of the current image at the crosshair's position is shown ???.
substituting <directory> with the directory, where you have vviewer.py.
Then you can launch the viewer as:
## Multiple images and overlay
You can display multiple images simultaneously, overlaid on each others. The order of the images can be changed with the two buttons ???. The most top image is also drawn on top all other ones. If you want to turn an image invisible, click on the checkmark ??? next to the image name. Vviewer shows you the values for the crosshair voxel for all images (with "a:" denoting the most top image, "b:" the one below, etc.)
vviewer.py -in bla.nii -z overlay.nii
## Colormap
### Basics
Images are displayed by a means of a colormap, which assigns a color to given values in the image. Per default, this is a gray-scale colormap, assigning black to the smallest value in your image and white to the largest. You can however manipulate the ending points of the color mapping with the slider ???. Pulling down the upper handle will change the value that is rendered as white. This value is shown ???. For instance, instead of drawing the maximum value of 500 as white, you may pull the upper handle to a value of 250. Thus, the value of 250 will be shown as white, and all values above 250 will also be shown as white (per default, this behaviour can be changed). Thus, the overall brightness of the image increases. Similarly, if you manipulate the lower handle of the slider, the value assigned to black is changed. It is shown ???. For instance, pulling the value from 0 to 100 means that the value 100 is now assigned to black. However, values below 100 are not drawn anymore and are invisible. This behaviour can be changed, see ???.
### Change the color map
You can change the colormap and select another one by clicking on the color map.
## Setup For Mac
### Two color maps
If you want to display positive and negative values with different colors, you can activate a second color bar. Just press "i" or go to image/image settings, and this will bring up the image menu. There, select "color maps" and "two color maps".
The second color map has its own sliders, which are shown to the right of the first one, allowing to set independent thresholds.
Same for Ubuntu only that you have to install pip using easy_install, homebrew, macport or get-pip.py from pip's home page.
### Clipping behaviour
What happens to values that are outside the range of the color map assignment? Per default, values ABOVE the upper limit are shown in the same color as the maximum for the color map. Values BELOW the lower limit are however not drawn and are invisible. We call this procedure "clipping". You can change the default behaviour in the image settings menu (press "i"), clicking the checkboxes regarding clipping.
## Windows
change Colorma
have two colormaps. sliders!
clipping properties
## Histogram
tools /histogram of "h"
linkage to the sliders
moving, shifting!
## Time series data
slider for Time
n and b and space
t or image/image time series
## Maximum and minimum
# Advanced
## Colormap Clipping
## Resampling options
##
#Keyboard shortcuts
cursor / page up down
h
c
v
space
n/b
w s
o
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment