---
name: "tff_validate_trx.py"
section: "1"
platform: "linux"
package: "python3-trx-python"
version: "0.3-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/tff_validate_trx.py"
---

# tff\_validate\_trx.py(1)

validate a TRX file

## NAME

tff\_validate\_trx.py - validate a TRX file

## DESCRIPTION

usage: tff\_validate\_trx.py \[-h\] \[--out\_tractogram OUT\_TRACTOGRAM\]

- \[--remove\_identical\_streamlines\]

  \[--precision PRECISION\] \[--reference REFERENCE\] \[-f\] in\_tractogram

Validate TRX file.

Removes streamlines that are out of the volume bounding box. In voxel space, no negative coordinate and no above volume dimension coordinate are possible. Any streamline that do not respect these two conditions are removed.

Also removes streamlines with single or no point. The **--remove\_identical\_streamlines** option will remove identical streamlines. 'identical' is defined as having the same number of points and the same points coordinates (to a specified precision, using a hash table).

### positional arguments:

- in\_tractogram

  Tractogram filename. Format must be one of trk, tck, vtk, fib, dpy, trx.

### options:

- **-h**, **--help**

  show this help message and exit

- **--out\_tractogram** OUT\_TRACTOGRAM

  Filename of the tractogram after removing invalid streamlines.

- **--remove\_identical\_streamlines**

  Remove identical streamlines from the set.

- **--precision** PRECISION

  Number of decimals to keep when hashing the points of streamlines \[1\].

- **--reference** REFERENCE

  Reference anatomy for tck/vtk/fib/dpy file support (.nii or .nii.gz).

- **-f**

  Force overwriting of the output files.
