convert_ctab_to_dseg#
- petpal.utils.useful_functions.convert_ctab_to_dseg(ctab_path: str, dseg_path: str, column_names: list[str] = None)#
Convert a FreeSurfer compatible color table into a BIDS compatible label map
dseg.tsv.- Parameters:
ctab_path (str) – Path to FreeSurfer compatible color table.
dseg_path (str) – Path to
dseg.tsvlabel mapfile to save.column_names (list[str]) – List of columns present in color table. Must include ‘mapping’ and ‘name’.