.. _scil_fibertube_score_tractogram: scil_fibertube_score_tractogram =============================== :: usage: __main__.py [-h] [--save_error_tractogram] [--out_tracked_fibertubes OUT_TRACKED_FIBERTUBES] [--indent INDENT] [--sort_keys] [-v [{DEBUG,INFO,WARNING,ERROR}]] [-f] in_fibertubes in_tracking in_config out_metrics Given ground-truth fibertubes and a tractogram obtained through fibertube tracking, computes metrics about the quality of individual fiber reconstruction. Each streamline is associated with an "Termination fibertube segment", which is the closest fibertube segment to its before-last coordinate. We then define the following terms: VC: "Valid Connection": A streamline whose termination fibertube segment is the final segment of the fibertube in which is was originally seeded. IC: "Invalid Connection": A streamline whose termination fibertube segment is the start or final segment of a fibertube in which is was not seeded. NC: "No Connection": A streamline whose termination fibertube segment is not the start or final segment of any fibertube. The "absolute error" of a coordinate is the distance in mm between that coordinate and the closest point on its corresponding fibertube. The average of all coordinate absolute errors of a streamline is called the "Mean absolute error" or "mae". Computed metrics: - vc_ratio Number of VC divided by the number of streamlines. - ic_ratio Number of IC divided by the number of streamlines. - nc_ratio Number of NC divided by the number of streamlines. - mae_min Minimum MAE for the tractogram. - mae_max Maximum MAE for the tractogram. - mae_mean Average MAE for the tractogram. - mae_med Median MAE for the tractogram. See also: - scil_tractogram_filter_collisions to prepare data for fibertube tracking - scil_fibertube_tracking to perform a fibertube tracking - docs/source/documentation/fibertube_tracking.rst positional arguments: in_fibertubes Path to the tractogram (must be .trk) file containing fibertubes. They must have their respective diameter saved as data_per_streamline. in_tracking Path to the tractogram file (must be .trk) containing the reconstruction of ground-truth fibertubes made from fibertube tracking. Seeds used for tracking must be saved as data_per_streamline. in_config Path to a json file containing the fibertube parameters used for the tracking process. out_metrics Output file containing the computed measures and metrics (must be .json). options: -h, --help show this help message and exit --save_error_tractogram If set, a .trk file will be saved, containing a visual representation of all the coordinate absolute errors of the entire tractogram. The file name is derived from the out_metrics parameter. --out_tracked_fibertubes OUT_TRACKED_FIBERTUBES If set, the fibertubes that were used for seeding will be saved separately at the specified location (must be .trk or .tck). This parameter is not required for scoring the tracking result, as the seeding information of each streamline is always saved as data_per_streamline. -v [{DEBUG,INFO,WARNING,ERROR}] Produces verbose output depending on the provided level. Default level is warning, default when using -v is info. -f Force overwriting of the output files. Json options: --indent INDENT Indent for json pretty print. --sort_keys Sort keys in output json. 2.2.2