.. _Base.TrackedSharedImageSetProperties: Tracking Properties =================== Changes properties such as calibration or registration of individual Tracking Sequences or Tracking Sequences within tracked image sets or ultrasound sweeps. Input ----- The algorithm requires either a single tracking sequence, or an arbitrary number of image sets that contain at least one tracking sequence each. In the latter case all sets need to have the same number of tracking sequences and if at least one set has timestamps, all the others need to have them as well. Output ------ None. The input tracking sequences are updated. Description ----------- The algorithm will open a dialog with three sections. The **Registration** and **Calibration** sections refer to the currently active tracking sequence. The **Tracking** section allows to scroll through the tracking sequence of an image set, in case there are multiple. In general, tracking sequences form a set of matrices *M[i]*, which are used to define where in space images or other data elements are located. Each tracking sequence contains two more matrices that relate to all tracking matrices. Using the convention that all matrices map to the world origin, the full transformation of a tracking sequence is: *T[i] = R * M[i] * C*, where *R* is the registration, and *C* the calibration. Note that there is a specialized version of this algorithm for ultrasound sweeps: :ref:`Sweep Tracking Properties`. Tracking Section ################ This section modifies which Tracking Sequence the calibration and registration settings on the other sections relate to, which tracking sequence is the main one, and the whether some tracking sequences should be relative to each other. ``Use sequence`` defines which tracking sequence is the main one, i.e. which one should be used to look up poses of images. Use this setting also to temporarily modify properties for other tracking sequences. When you want to change for instance the calibration of the second tracking sequence, select it here, switch to the calibration section and adjust the matrix, and finally switch back to set the main tracking sequence back to the first one. The ``Invert`` checkbox sets a flag so that all matrices will be inverted on look-up. The **Delete** removes the selected tracking sequence. If the ``Relative to`` checkbox is checked, the main tracking sequence selected under ``Use sequence`` will be relative to the tracking sequence selected here. By default, the ``wrt. first`` checkbox is unchecked, i.e. for every image, the timestamps are used to determine the tracking information of both tracking sequences. Otherwise, only the very first matrix of the relative tracking sequence is used, for instance when the reference tracking target was never moved and its matrices only contain tracking noise. Extensive ``Filter`` options are available to post-process tracking data, either on the translations along (*Trans*) or also on the rotation (*Trans+Rot*). If the ``Gaussian`` checkbox is checked, a Gaussian kernel of size ``Size`` is used, otherwise a rectangular one. The checkbox ``determines`` whether the filter should consider the matrices' timestamps. Finally, if the ``Balance`` checkbox is checked, different number of tracking samples before and after the center one being considered are balanced out to avoid a drift. The ``Show All Trackings`` option turns on a visualization of all tracking targets on. Be aware that mixing relative and non-relative tracking sequences might lead to unintuitive results due to the different base coordinate systems. Within the ``Tracking Instrument`` group, meta data of the currently selected tracking sequence is shown and can be edited. The name is used for visualization, including the quality bars at the bottom of the views. The group ``Tracking Sequence Quality Criteria`` contains controls to set the criteria that is used to determine the quality of tracking samples in the sequence based on their timestamps. This can be used to detect a loss of tracking that can occur e.g. due to visibility of the tracking target. Selecting ``None`` will not use the timestamps for quality assessment. ``Average`` and ``Median`` will use the average or median time difference between tracking samples as a threshold respectively. The option ``User Defined`` allows to set a custom threshold. Samples with a time difference to the previous sample larger than the threshold will be considered invalid. Checking ``Apply to all Tracking Sequences`` will apply the same criteria to all tracking sequences of the same image set. The button **Generate Equi-Timestamp Tracking Sequences** resamples the tracking sequence so that all tracking sequences use the same timestamps as the main one. Calibration Section ################### This section allows to define spatial and temporal calibrations. The ``Calibration Matrix`` *C* can be defined using translations and Euler angles. Use the dropdown menus to switch between *Absolute* and *Relative* coordinate frames, and which mapping direction (regular matrix or its inverse) you want to edit the matrix in. The ``Temporal Calibration`` is a time offset that is used when relating images to tracking data. The ``Timestamps`` checkbox toggles whether timestamps of images and tracking data (plus the temporal calibration offset) shall be used to determine a tracking pose of each image. If unchecked, the first image will use the first tracking pose, etc. If the ``Apply to all Tracking Sequences`` checkbox is checked, any changes to the temporal controls above will be applied to all tracking sequences of the same image set. Usually, all tracking sequences are acquired with the same tracking hardware and thus shared the temporal calibration offset. Registration Section #################### Similar to the calibration matrix, this section allows to define the ``Registration Matrix`` *R* using translations and Euler angles. The **Center** button conveniently adjusts the registration matrix so that the center of gravity of the tracking samples are in the world origin.