.. _scil_tractogram_detect_loops: scil_tractogram_detect_loops ============================ :: usage: __main__.py [-h] [--looping_tractogram out_filename] [--qb [threshold]] [--angle ANGLE] [--display_counts] [--no_empty] [--indent INDENT] [--sort_keys] [--processes NBR] [--reference REFERENCE] [-v [{DEBUG,INFO,WARNING,ERROR}]] [-f] in_tractogram out_tractogram This script can be used to remove loops in two types of streamline datasets: - Whole brain: For this type, the script removes streamlines if they make a loop with an angle of more than 360 degrees. It's possible to change this angle with the --angle option. Warning: Don't use --qb option for a whole brain tractography. - Bundle dataset: For this type, it is possible to remove loops and streamlines outside the bundle. For the sharp angle turn, use --qb option. See also: scil_tractogram_filter_by_anatomy ------------------------------------------------------------------------------ Reference: [1] QuickBundles, based on [Garyfallidis12] Frontiers in Neuroscience, 2012. ------------------------------------------------------------------------------ positional arguments: in_tractogram Tractogram input file name. out_tractogram Output tractogram without loops. options: -h, --help show this help message and exit --looping_tractogram out_filename If set, saves detected looping streamlines. --qb [threshold] If set, uses QuickBundles to detect outliers (loops, sharp angle turns). Given threshold is the maximal streamline to bundle distance for a streamline to be considered as a tracking error. Default if set: [8.0] --angle ANGLE Maximum looping (or turning) angle of a streamline in degrees. [360] --display_counts Print streamline count before and after filtering --no_empty If set, will not save outputs if they are empty. --processes NBR Number of sub-processes to start. Default: [1] --reference REFERENCE Reference anatomy for tck/vtk/fib/dpy file support (.nii or .nii.gz). -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