Skip to main content
Skip table of contents

Using the XNAT OHIF Viewer

General Overview

Full Window Viewer

From the Actions box in Subject/Session page within the XNAT webapp:

  • Left clicking View Images will open the viewer in the active window.
  • Middle/Right clicking View Images will open the viewer in a new tab/window depending on browser configuration.

Synchronization and Smoothing Options

  • Using the sync toggles at the top right of each viewport, one can synchronize scans to scroll together.

  • The 'Options/Preferences/General' menu lets the user switch the synchronization strategy to operate via image position or by frame number. Image position is the default.


Contouring Overview

A "Region of Interest" Contour (ROI Contour) is defined as a collection of 2D contours that make up a continuous volume. The Contours side panel displays a list of ROI Contours displayed on the scan in the active viewport, as well as some global settings for ROI Contour tools.

Contour List


  • Click on the "+ Contour ROI" button to add a new ROI Contour.
  • Click on a ROI Contour's name to edit it.
  • Click on the number of contours (N) to jump to the slice nearest to the ROI center.

Import



You may import as many ROI Collections as you wish, you don't need to be viewing the correct scan in order to import it. Imported ROI Collections come in locked (viewable but not editable). You can unlock these by clicking on the unlock symbol, each ROI Contour will then be moved to the New ROI Contour Collection, allowing you to edit the ROI Contours and resave them as a different collection.

Export


You may choose which ROI Contours to export together as a collection. You must give the collection a human readable name. If there is only one ROI Contour in the list, the collection name will default to the ROIContour name.

Settings

Interpolation




Toggles contour interpolation. When turned on, drawing new 2D contours will produce intermediate contours estimated by linear interpolation.

  • Interpolated contours are denoted by a dotted line.
  • Interpolated contours are recalculated every time a source contour (solid line) is edited.
  • If you edit an interpolated contour, it becomes a source contour.
  • Interpolation won't occur if there are multiple contours of the same ROI on a frame, due to ambiguity.

Stats







Toggles the display of ROI Contour statistics on the screen.

Enabled

  • The statistics for each ROI will be displayed on the screen.
  • Statistic windows can be moved by dragging them with the mouse.
  • Statistic windows will be present in exported snapshots.

Disabled

  • The statistics can be viewed by hovering over an ROI's node.
  • If a stats window has been moved, the stats window will display at that location.





  




  


Contouring Tools

Draw Tool








The ROI Draw tool is used to create and edit contours of an ROI.

Draw Polygons

  • Click to draw a node.
  • Keep clicking to draw the contour point by point.
  • Complete the contour by clicking on the origin node without crossing any lines.

Draw Freehand

  • Hold the mouse to start drawing.
  • Drag the mouse to draw the contour.
  • Complete the contour by releasing the mouse at the origin node without crossing any lines.

 


Edit

  • Ctrl-click on a handle to delete it.
  • Ctrl-click on a line to insert a new handle.
  • Drag a handle to move it.

Shortcuts

  • Pressing 'c' key whilst drawing will cancel the contour you are drawing.
  • Pressing 'enter' key whilst drawing will quickly close the contour.

 


Context Menu

Right-click on any node in a contour to show context menu.

  • Delete contour: removes that contour.
  • Copy contour: copies the contour data to clipboard.

If the contour clipboard isn't empty, clicking anywhere on the image shows another context menu.

  • Paste contour: pastes contour with data from the clipboard on the current image slice. Advanced paste functions will be implemented in future releases.
  • Empty clipboard: clears the contour data stored in the clipboard.

Sculpt Tool












This tool is used to sculpt contours drawn with the freehand tool.

Select ROI

  • Double click near a contour to select it for editing.
  • A cursor touching the edge of the contour will appear to show its selected.

Edit ROI

  • Hold down left click near the selected tool to begin editing.
    • The closer to the contour the mouse is, the smaller the tool will be.
    • The tool can push from both inside and outside the contour.
  • With the mouse held down, drag the tool to push the ROI.
    • New points will be created and deleted as needed.
  • Release the mouse to complete the edit.

You may find you wish to make rough edits with a large tool, before making fine adjustments with a finer tool.






Masking Overview

A segment is defined as a 3D mask of a particular color, defining one region of interest. The "Mask-based ROIs" side panel displays a list of segments displayed on the scan in the active viewport, as well as settings relevant to the active masking tool.

Segment List




New Mask Collection

  • Click on the "+ Add" button to add a new segment.
  • Click "Remove" to delete a segment from your working collection.
  • Click on a segment's label or type to edit its metadata.
  • Click hide to hide a segment.
  • Click on the "Palette" button to select which color to paint.

Import


You may overlay one labelmap on a scan at a time. This limitation is due to memory limitations within the browser, and will be improved in the future. You may edit the labelmap and re-save it as a new ROI Collection.
ExportYou can export the labelmap. Overlapping segments are valid and can be exported.

Shortcuts


The following shortcuts are available (where applicable) for all masking tools.

  • Use the [ and ] keys to increase/decrease the brush size.
  • Ctrl + click before drawing to erase selected mask color.





  

Masking Tools

Manual Tool

The Manual Brush tool allows you to segment images with a circular brush.

Painting with the brush

  • Click on the canvas to paint with the selected color.
  • Drag to make brush strokes.
  • Ctrl + click before drawing to erase selected mask color.
  • Use the [ and ] keys to increase/decrease the brush size.


Smart CT Tool

The smart CT brush tool allows you to segment specific tissue types of CT images based on a pair of Hounsfield Units (HU). The tissue type can be chosen in the Brush Settings menu, as well as a custom HU gate.

Holes/artifacts are filled and stray pixels removed, based on the settings configured in the Segments side panel.

Painting with the brush

  • Click on the canvas to paint with the selected color.
  • Drag to make brush strokes.

Smart CT Gate Selection

This option allows you to select the tissue type the Smart CT brush uses. You can also specify a custom gate in Hounsfield Units.

Smart/Auto Gate Settings

These settings affect both the Smart CT and Auto Brush tools.

  • The first slider sets the size of holes to fill in whilst painting, as a fraction of the primary region painted within the brush circle.
  • The second slider sets the size of non-primary regions to ignore whilst painting, as a fraction of the primary region painted within the brush circle. Regions smaller than this threshold will not be painted.

Auto Tool

The Auto Brush tool finds the minimum and maximum pixel values within the brush radius when pressing down the mouse. Dragging after pressing down the mouse will only fill in pixels within this band.

Holes/artifacts are filled and stray pixels removed, based on the settings configured in the Segments side panel.

Painting with the brush

  • Click on the canvas to paint with the selected color.
  • Drag to make brush strokes.
Smart/Auto Gate Settings apply to the Auto Tool.

NVIDIA AIAA Tools

The viewer integrates the NVIDIA AI-Assisted Annotation tools listed below.

This feature is currently experimental. It can be enabled/disabled from the "Experimental Features" section in "Option/Preferences" header menu.
To use this feature, an AIAA server URL should be set by a site administrator using the /ohifaiaa/projects/{projectId}/servers REST API call.


How to enable the AIAA Tools?

Annotation (DEXTR3D)

The DEXTR3D (or Deep Extreme cut in 3D) tool requires to provide 6+ extreme points on the edges of an organ.

  • Select "Annotation" from the "AIAA tool" dropdown list.
  • Select which model to use from the "Annotation models" dropdown list.
  • Click 6+ points on edges around an organ. The points can be selected over multiple slices.
  • Once the first 6 points were selected, the viewer will request from the server to run the analysis using the chosen model. The result of annotation is painted on the image in 3D after it was received back from the AIAA server.
  • The clicks for consecutive points initiate the annotation requests and result rendering automatically for each additional point.

Example DExtr3D-based annotation of spleen

Deepgrow

Deepgrow annotation requires a single point, but can then be refined progressively by addition of more points.

Deepgrow runs in 2D only.
  • Select "Deepgorw" from the "AIAA tool" dropdown list.
  • Click to add a foreground point within an organ/ROI. The points can be selected over multiple slices, but the annotation is only performed for the current slice.
  • Once a point was clicked, the viewer will request from the server to run the analysis. The result is rendered back on the currently displayed slice in the viewer.
  • To clear areas with over-segmentation, use ctrl + click to add a background point.

Example Deepgrow annotation of kidneys

Auto Segmentation

Fully automated segmentation with no additional input.

  • Select "Segmentation" from the "AIAA tool" dropdown list.
  • Select which model to use from the "Segmentation models" dropdown list.
  • Click "Run".



Example auto segmentation of lungs

Other Masking Tools

A group of standard tools for manipulating labelmap data.

Circle Scissors Tool

  • Click once on the canvas to set the circle center.
  • Drag outwards of the center and release to fill with the selected color.
  • Ctrl + click before drawing to erase selected mask color.

Rectangle Scissors Tool

  • Click once on the canvas to set one corner or the rectangle.
  • Drag around the corner and release to fill with the selected color.
  • Ctrl + click before drawing to erase selected mask color.

Freehand Scissors Tool

  • Click once and drag the mouse around the region of interest.
  • Release the mouse to fill with the selected color.
  • Ctrl + click before drawing to erase selected mask color.

Spherical Brush Tool

Similar to the manual brush but it paints mask in 3D.

  • Click on the canvas to paint with the selected color.
  • Drag to make brush strokes.
  • Ctrl + click before drawing to erase selected mask color.
  • Use the [ and ] keys to increase/decrease the brush size.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.