Checking image registration

This viewer and widget are designed to compare two images and check if the registration was correct.

class CheckboardView(render_window_interactor, reader, widget)[source]

Viewer to compare two images

change_space(*args, **kwargs)[source]

Change current coordinate system

new_space (str) : new coordinate system, see get()

get_number_of_image_slices()[source]

Gets the number of slices available in the current direction

Returns:The number of available slices
reset_camera(*args, **kwargs)[source]

resets the current camera to standard locations.

Parameters:position (int) –
  • 0: initial 3d view
  • 1: left
  • 2: right
  • 3: front
  • 4: back
  • 5: top
  • 6: bottom
set_image_slice(*args, **kwargs)[source]

Set plane widget slice

Parameters:new_slice (int) – Index of desired slice
set_img1(*args, **kwargs)[source]

Sets the first image

Parameters:
set_img2(*args, **kwargs)[source]

Sets the second image

Parameters:
set_number_of_divisions(*args, **kwargs)[source]

Set number of divisions in the checkboard pattern

Parameters:divs (int) – Number of divisions
set_orientation(*args, **kwargs)[source]

Sets orientation of the plane widget

Parameters:orientation_int (int) – 0 is x, 1 is y, 2 is z
update_pipeline()[source]

Updates the whole visualization pipeline

class QCheckViewer(reader, parent)[source]

Wraps the CheckboardView so that in can be connected to Qt applications.

initialize_widget()[source]

Call this function after calling show on the widget or a parent

slice_change_handle(new_slice)[source]

Emits a qt signal when the current slice is changed from vtk

viewer

Access to internal CheckboardView object