Difference between revisions of "2016 Winter Project Week/Projects/TrackedUltrasoundStandardization"

From NAMIC Wiki
Jump to: navigation, search
 
(34 intermediate revisions by 6 users not shown)
Line 1: Line 1:
__NOTOC__
 
 
<gallery>
 
<gallery>
 
Image:PW-MIT2016.png|link=2016_Winter_Project_Week#Projects|[[2016_Winter_Project_Week#Projects|Projects List]]
 
Image:PW-MIT2016.png|link=2016_Winter_Project_Week#Projects|[[2016_Winter_Project_Week#Projects|Projects List]]
Line 5: Line 4:
  
 
==Key Investigators==
 
==Key Investigators==
 +
[[Image:UltrasoundToolGuidance3dOnly.gif|right]]
 
* Andras Lasso, Tamas Ungi (PerkLab, Queen's University)
 
* Andras Lasso, Tamas Ungi (PerkLab, Queen's University)
 
* Christian Askeland, Ingerid Reinertsen, Ole Vegard Solberg (CustusX, IGT research, SINTEF)
 
* Christian Askeland, Ingerid Reinertsen, Ole Vegard Solberg (CustusX, IGT research, SINTEF)
Line 15: Line 15:
 
==Project Description==
 
==Project Description==
 
{| class="wikitable"
 
{| class="wikitable"
 +
! style="text-align: left; width:27%" |  Objective
 +
! style="text-align: left; width:27%" |  Approach and Plan
 +
! style="text-align: left; width:27%" |  Progress and Next Steps
 
|- style="vertical-align:top;"
 
|- style="vertical-align:top;"
! style="text-align: left; width:27%" | Objective
+
|
 
* Establish a common software platform for tracked ultrasound and image-guided interventions by converging existing IGT toolkits:
 
* Establish a common software platform for tracked ultrasound and image-guided interventions by converging existing IGT toolkits:
 
** [http://www.slicer.org 3D Slicer], [http://www.slicerigt.org SlicerIGT extension]
 
** [http://www.slicer.org 3D Slicer], [http://www.slicerigt.org SlicerIGT extension]
 
** [http://www.plustoolkit.org Plus toolkit]
 
** [http://www.plustoolkit.org Plus toolkit]
 
** [http://custusx.org/ CustusX]
 
** [http://custusx.org/ CustusX]
** [http://www.bic.mni.mcgill.ca/ServicesSoftwareVisualization/IBIS IBIS]
+
** [http://www.bic.mni.mcgill.ca/~sdrouin/Ibis IBIS]
 
** [http://www.imaging.robarts.ca/petergrp/Technology Echelon]
 
** [http://www.imaging.robarts.ca/petergrp/Technology Echelon]
 
** [http://mitk.org/wiki/IGT MITK-IGT]
 
** [http://mitk.org/wiki/IGT MITK-IGT]
! style="text-align: left; width:27%" | Approach, Plan
+
|
 
* Pre-Project Week online meetings and emails
 
* Pre-Project Week online meetings and emails
 
** Notes below
 
** Notes below
** [https://github.com/SINTEFMedtek/CustusX/wiki/OpenIGTLink-US-messaging-proposal Design document from SINTEF]
+
** SINTEF design document [https://github.com/SINTEFMedtek/CustusX/wiki/OpenIGTLink-US-messaging-proposal]
 
* Coordination with the CommonTK effort
 
* Coordination with the CommonTK effort
 
* Survey of current implementations and use cases
 
* Survey of current implementations and use cases
 
* Development of long-term development practices to encourage collaboration
 
* Development of long-term development practices to encourage collaboration
!! style="text-align: left; width:27%" | Progress
+
|
*
+
* IGSIO [https://github.com/igsio]
 +
* Preparation meeting minutes [[2016_Winter_Project_Week:TrackedUltrasoundStandardization/PreparationMeetings|[0]]]
 +
* Live meeting minutes [https://docs.google.com/document/d/1jOHkFQJ5-GPyT3b9XHBJ5rnVkNOQQ2Q6G6evTfnl-CU/edit?usp=sharing]
 +
|}
 +
 
 +
== OpenIGTLink Revisions ==
 +
v3 proposal document [http://openigtlink.org/protocols/v3_proposal.html]
 +
=== Tracked ultrasound OpenIGTLink client ===
 +
* Move out part of OpenIGTLinkIF
 +
* Only use OpenIGTLink and VTK
 +
 
 +
====Commands====
 +
=====SetDeviceParameters=====
 +
<b>Message</b>
 +
<Command>
 +
  <Parameter Name=”Depth” Value=”45” />
 +
  <Parameter Name=”Gain” Value=”35” />
 +
</Command>
 +
 
 +
<b>Response 1</b>
 +
<Command>
 +
  <Result>SetDeviceParameters: success</Result>
 +
  <Parameter Name=”Depth” Value=”45” />
 +
  <Parameter Name=”Gain” Value=”35” />
 +
  ...
 +
</Command>
 +
 
 +
<b>Response 2</b>
 +
<Command>
 +
  <Result>SetDeviceParameters: failure</Result> <!-- see command status error code -->
 +
</Command>
 +
 
 +
=====GetDeviceParameters=====
 +
<b>Message</b>
 +
<Command>
 +
  <Parameter Name=”Depth” />
 +
  <Parameter Name=”Gain” />
 +
  ...
 +
</Command>
 +
 
 +
<b>Response</b>
 +
<Command>
 +
  <Result>GetDeviceParameters: success</Result>
 +
  <Parameter Name=”Depth” Value=”45” />
 +
  <Parameter Name=”Gain” Value=”35” />
 +
  ...
 +
</Command>
 +
 
 +
=====SubscribeDeviceParameters=====
 +
This will cause the server to send a GetDeviceParameters reply every time any of the subscribed parameters change.
 +
 
 +
<b>Message</b>
 +
<Command>
 +
  <Parameter Name=”Depth” Subscribe=”TRUE” />
 +
  <Parameter Name=”Gain” Subscribe=”FALSE” />
 +
  ...
 +
</Command>
 +
 
 +
<b>Response</b>
 +
<Command>
 +
  <Result>SubscribeDeviceParameters: success</Result>
 +
  <Parameter Name=”Depth” Subscribed="TRUE" />
 +
  <Parameter Name=”Gain” Subscribed="FALSE" />
 +
  ...
 +
</Command>
 +
 
 +
=====GetCapabilities=====
 +
SINTEF will specify and implement.
 +
 
 +
<b>Message</b>
 +
<Command></Command>
 +
 
 +
<b>Response</b>
 +
<Command>
 +
  <Result>GetCapabilities: success</Result>
 +
  <UltrasoundCapabilities>
 +
    <Probes>
 +
      <Probe name="L14-5/38"/>
 +
      <Probe name="C5-2/42"/>
 +
    </Probes>
 +
    <ImagingModes>
 +
      <ImagingMode Name=”b-mode+angio”>B-Mode,Angio</ImagingMode>
 +
    </ImagingModes>
 +
    <Streams>
 +
      <Stream name="B-Mode">
 +
        <Parameters>
 +
          <Parameter name="depth" min="5" max="220" step="5"/>
 +
        </Parameters>
 +
      </Stream>
 +
      <Stream name="Angio">
 +
        <Parameters>
 +
          <Parameter name="depth" min="5" max="220" step="5"/>
 +
        </Parameters>
 +
      </Stream>
 +
    </Streams>
 +
    <Presets>
 +
      <Preset name="Vascular small object B+Angio">
 +
        <Probe Name=”L14-5/38” />
 +
        <Parameter Name=”Depth” Value=”50” />
 +
      </Preset>
 +
    </Presets>
 +
  </UltrasoundCapabilities>
 +
</Command>
 +
===Tracking===
 +
Tracked ultrasound communication will use the TDATA message.
 +
 
 +
Use 1 bit of the Reserved byte to indicate valid/invalid status
 +
 
 +
Use metadata attributes for tool status information:
 +
 
 +
====Attributes====
 +
<ToolStatus>
 +
  <Tool Id=”Reference” Status=”WARNING” Description=”Marker 1 on tool X is damaged” />
 +
</ToolStatus>
  
|}
+
* Status
 +
** "OK"
 +
** "WARNING"
 +
** "ERROR"
 +
* Description: human-readable string
 +
 
 +
===Meta Data===
 +
====Header V1====
 +
Bytes
 +
0  2                      14                                      34              42              50              58
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
 +
| V | TYPE                  | DEVICE_NAME                          | TIME_STAMP    | BODY_SIZE    | CRC64        |
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
 +
 
 +
====Header V2====
 +
<nowiki>#</nowiki>Bytes HEADER_FIELD
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
 +
0 V 2 TYPE 14 DEV_NAME 34 TS 42 BODY_SIZE 50 CRC64 58 EXT_HEADER_SIZE 60 METADATA_SIZE 64 MSG_ID 68 RV 72 CONTENT… | METADATA… |
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
 +
* V = VERSION
 +
* DEV_NAME = DEVICE_NAME
 +
* RV = RESERVED
 +
 
 +
=====EXT_HEADER=====
 +
v1 header (58 bytes) + new header (EXT_HEADER_SIZE bytes)
 +
 
 +
=====CONTENT (=v1 body)=====
 +
BODY_SIZE - EXT_HEADER_SIZE - METADATA_SIZE
 +
 
 +
=====METADATA=====
 +
<nowiki>#</nowiki>Bytes HEADER_FIELD
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
 +
|INDEX_COUNT (uint16) | KEY_SIZE (uint16) | VALUE_ENCODING (uint16) | VALUE_SIZE (uint32) | … | KEY | VALUE | … |
 +
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
 +
 
 +
=====VALUE_ENCODING=====
 +
As specified at http://www.iana.org/assignments/character-sets/character-sets.xhtml
 +
 
 +
=====BODY=====
 +
Contains extended header data, message content, and metadata.
 +
 
 +
==US over OpenIGTLink==
 +
===Parameters===
 +
<b>Read-write</b>
 +
* Depth (mm): (“40”, “45”, “50”, …)
 +
* ImagingMode (string): (“bmode”, “bmode+rf”, “bmode+angio”, “rf+angio”, ...)
 +
* Probe (string): probe name (“L14-5/38”)
 +
* Frequency (MHz)
 +
* DynRange (db)
 +
* Gain (%)
 +
* Power (%)
 +
* Zoom (%)
 +
* SoundVelocity (m/s)
 +
* TGC (space-separated string, each entry -1.0 to 1.0)
 +
* AcquisitionState (string): “FREEZE” or “RUN”
 +
 
 +
<b>Read-only</b>
 +
* ClipRectangleOrigin="27 27"
 +
* ClipRectangleSize="766 562"
 +
* FanAnglesDeg=”-30 30” (for 3D: FanAnglesDeg=”-30 30 -15 15”)
 +
* FanOriginPixel=”240 10”
 +
* FanRadiusStartPixel=”30”
 +
* FanRadiusStopPixel=”500”
 +
* Encoding: how to interpret values ("BRIGHTNESS", "RF_REAL", "RF_IQ_LINE", "RF_I_LINE_Q_LINE", "RGB_COLOR")
  
<h3>Preparation meetings</h3>
+
== Implementation plan ==
 +
=== Tasks ===
 +
* Clean up the vtkMRMLIGTLConnectorNode to be logic, MRML and Slicer free
 +
* Creating a new converter base class which does not depend on MRML
 +
* Implementation of the new Command Message
 +
=== Github Fork ===
 +
* OpenIGTLinkIF fork [https://github.com/drouin-simon/OpenIGTLinkIF]
 +
* OpenIGTLink fork [https://github.com/lassoan/OpenIGTLink]
 +
=== PLUS ===
 +
* Interson probe settings [https://www.assembla.com/spaces/plus/tickets/869-interson-probe-settings-/details]
 +
* Interson class cleanup [https://www.assembla.com/spaces/plus/tickets/897-clean-up-interson-video-source-code/details]
 +
* Get/Set TGC support for US devices [https://www.assembla.com/spaces/plus/tickets/1056-add-tgc-support-to-ultrasonix-interface/details]
 +
* Get transform over OpenIGTLink [https://www.assembla.com/spaces/plus/tickets/1054-add-get_transform-command-to-plus-server-to-support-querying-of-transforms/details]
 +
* Sonix transition to imaging parameters [https://www.assembla.com/spaces/plus/tickets/1058-convert-sonixvideo-source-to-use-new-imaging-parameters-design/details]
  
'''[[2016_Winter_Project_Week:TrackedUltrasoundStandardization/PreparationMeetings|=> See preparation meetings page]]'''
+
=== CustusX ===
 +
* Example CustusX class [https://github.com/SINTEFMedtek/CustusX/blob/master/source/resource/OpenIGTLinkUtilities/cxIGTLinkConversionImage.h]
  
'''Link to join the meeting at 9am (EST) on Dec 14, 2015: https://plus.google.com/u/0/events/cna4d11el56n6lhkaqrupqlu8tk?authkey=CLnh6Zza0dTHFw'''
+
==Presentations==
 +
* [[Media:NAMIC - IGT - Adam Rankin.pptx|Adam Rankin, Robarts Research Institute]]
 +
* [[Media:PerkLabTrackedUs.pdf|Andras Lasso, PerkLab, Queen's University]]
 +
* [[Media:MITKTrackedProbes.pdf|Thomas Kirchner, CAI group, German Cancer Research Center]]

Latest revision as of 18:40, 8 January 2016

Home < 2016 Winter Project Week < Projects < TrackedUltrasoundStandardization

Key Investigators

UltrasoundToolGuidance3dOnly.gif
  • Andras Lasso, Tamas Ungi (PerkLab, Queen's University)
  • Christian Askeland, Ingerid Reinertsen, Ole Vegard Solberg (CustusX, IGT research, SINTEF)
  • Simon Drouin (Mcgill University, Montreal, Canada)
  • Junichi Tokuda (BWH)
  • Steve Pieper (Isomics)
  • Adam Rankin (VASST Laboratory, Western University, Canada)
  • Thomas Kirchner, Janek Gröhl (MITK, DKFZ, Heidelberg, Germany)

Project Description

Objective Approach and Plan Progress and Next Steps
  • Pre-Project Week online meetings and emails
    • Notes below
    • SINTEF design document [1]
  • Coordination with the CommonTK effort
  • Survey of current implementations and use cases
  • Development of long-term development practices to encourage collaboration
  • IGSIO [2]
  • Preparation meeting minutes [0]
  • Live meeting minutes [3]

OpenIGTLink Revisions

v3 proposal document [4]

Tracked ultrasound OpenIGTLink client

  • Move out part of OpenIGTLinkIF
  • Only use OpenIGTLink and VTK

Commands

SetDeviceParameters

Message

<Command>
  <Parameter Name=”Depth” Value=”45” />
  <Parameter Name=”Gain” Value=”35” />
</Command>

Response 1

<Command>
  <Result>SetDeviceParameters: success</Result>
  <Parameter Name=”Depth” Value=”45” />
  <Parameter Name=”Gain” Value=”35” />
  ...
</Command>

Response 2

<Command>
  <Result>SetDeviceParameters: failure</Result> 
</Command>
GetDeviceParameters

Message

<Command>
  <Parameter Name=”Depth” />
  <Parameter Name=”Gain” />
  ...
</Command>

Response

<Command>
  <Result>GetDeviceParameters: success</Result>
  <Parameter Name=”Depth” Value=”45” />
  <Parameter Name=”Gain” Value=”35” />
  ...
</Command>
SubscribeDeviceParameters

This will cause the server to send a GetDeviceParameters reply every time any of the subscribed parameters change.

Message

<Command>
  <Parameter Name=”Depth” Subscribe=”TRUE” />
  <Parameter Name=”Gain” Subscribe=”FALSE” />
  ...
</Command>

Response

<Command>
  <Result>SubscribeDeviceParameters: success</Result>
  <Parameter Name=”Depth” Subscribed="TRUE" />
  <Parameter Name=”Gain” Subscribed="FALSE" />
  ...
</Command>
GetCapabilities

SINTEF will specify and implement.

Message

<Command></Command>

Response

<Command>
  <Result>GetCapabilities: success</Result>
  <UltrasoundCapabilities>
    <Probes>
      <Probe name="L14-5/38"/>
      <Probe name="C5-2/42"/>
    </Probes>
    <ImagingModes>
      <ImagingMode Name=”b-mode+angio”>B-Mode,Angio</ImagingMode>
    </ImagingModes>
    <Streams>
      <Stream name="B-Mode">
        <Parameters>
          <Parameter name="depth" min="5" max="220" step="5"/>
        </Parameters>
      </Stream>
      <Stream name="Angio">
        <Parameters>
          <Parameter name="depth" min="5" max="220" step="5"/>
        </Parameters>
      </Stream>
    </Streams>
    <Presets>
      <Preset name="Vascular small object B+Angio">
        <Probe Name=”L14-5/38” />
        <Parameter Name=”Depth” Value=”50” />
      </Preset>
    </Presets>
  </UltrasoundCapabilities>
</Command>

Tracking

Tracked ultrasound communication will use the TDATA message.

Use 1 bit of the Reserved byte to indicate valid/invalid status

Use metadata attributes for tool status information:

Attributes

<ToolStatus>
  <Tool Id=”Reference” Status=”WARNING” Description=”Marker 1 on tool X is damaged” />
</ToolStatus>
  • Status
    • "OK"
    • "WARNING"
    • "ERROR"
  • Description: human-readable string

Meta Data

Header V1

Bytes
0   2                       14                                      34              42              50              58
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| V | TYPE                  | DEVICE_NAME                           | TIME_STAMP    | BODY_SIZE     | CRC64         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Header V2

#Bytes HEADER_FIELD

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
0 V 2 TYPE 14 DEV_NAME 34 TS 42 BODY_SIZE 50 CRC64 58 EXT_HEADER_SIZE 60 METADATA_SIZE 64 MSG_ID 68 RV 72 CONTENT… | METADATA… |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
  • V = VERSION
  • DEV_NAME = DEVICE_NAME
  • RV = RESERVED
EXT_HEADER

v1 header (58 bytes) + new header (EXT_HEADER_SIZE bytes)

CONTENT (=v1 body)

BODY_SIZE - EXT_HEADER_SIZE - METADATA_SIZE

METADATA

#Bytes HEADER_FIELD

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|INDEX_COUNT (uint16) | KEY_SIZE (uint16) | VALUE_ENCODING (uint16) | VALUE_SIZE (uint32) | … | KEY | VALUE | … |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
VALUE_ENCODING

As specified at http://www.iana.org/assignments/character-sets/character-sets.xhtml

BODY

Contains extended header data, message content, and metadata.

US over OpenIGTLink

Parameters

Read-write

  • Depth (mm): (“40”, “45”, “50”, …)
  • ImagingMode (string): (“bmode”, “bmode+rf”, “bmode+angio”, “rf+angio”, ...)
  • Probe (string): probe name (“L14-5/38”)
  • Frequency (MHz)
  • DynRange (db)
  • Gain (%)
  • Power (%)
  • Zoom (%)
  • SoundVelocity (m/s)
  • TGC (space-separated string, each entry -1.0 to 1.0)
  • AcquisitionState (string): “FREEZE” or “RUN”

Read-only

  • ClipRectangleOrigin="27 27"
  • ClipRectangleSize="766 562"
  • FanAnglesDeg=”-30 30” (for 3D: FanAnglesDeg=”-30 30 -15 15”)
  • FanOriginPixel=”240 10”
  • FanRadiusStartPixel=”30”
  • FanRadiusStopPixel=”500”
  • Encoding: how to interpret values ("BRIGHTNESS", "RF_REAL", "RF_IQ_LINE", "RF_I_LINE_Q_LINE", "RGB_COLOR")

Implementation plan

Tasks

  • Clean up the vtkMRMLIGTLConnectorNode to be logic, MRML and Slicer free
  • Creating a new converter base class which does not depend on MRML
  • Implementation of the new Command Message

Github Fork

  • OpenIGTLinkIF fork [5]
  • OpenIGTLink fork [6]

PLUS

  • Interson probe settings [7]
  • Interson class cleanup [8]
  • Get/Set TGC support for US devices [9]
  • Get transform over OpenIGTLink [10]
  • Sonix transition to imaging parameters [11]

CustusX

  • Example CustusX class [12]

Presentations