User Guide#
- Getting started with pyAFQ
- Tutorials: Getting started
- Getting started with pyAFQ - GroupAFQ
- Example data
- Set tractography parameters (optional)
- Define PVE images (optional)
- Brain Mask Definition (optional)
- Initialize a GroupAFQ object:
- Calculating DTI FA (Diffusion Tensor Imaging Fractional Anisotropy)
- Visualize the result with Matplotlib
- Recognizing the bundles and calculating tract profiles:
- Visualizing the bundles and calculating tract profiles:
- Exporting citations
- Alternative way to initialize GroupAFQ when using QSIPrep data
- References
- Getting started with pyAFQ - ParticipantAFQ
- Example data
- Defining data files
- Set tractography parameters (optional)
- Define PVE images (optional)
- Brain Mask Definition (optional)
- Initialize a ParticipantAFQ object:
- Calculating DTI FA (Diffusion Tensor Imaging Fractional Anisotropy)
- Visualize the result with Matplotlib
- Recognizing the bundles and calculating tract profiles:
- Visualizing the bundles and calculating tract profiles:
- Exporting citations
- References
- Re-running pyAFQ
- Exporting pyAFQ Results
- Visualizing AFQ derivatives
- Get some data from HBN POD2
- Read data into memory
- Transform into the T1w reference frame
- Visualizing bundles with principal direction coloring
- Slicer actors
- Making a
scene - Showing the visualization
- Record the visualization
- Setting bundle colors
- Adding core bundles with tract profiles
- Adding ROIs
- Visualizing tracts and tract profiles with a “glass brain”
- Making a Figure out of many fury panels
- References
- How pyAFQ uses BIDS
- Plotting Default Regions of Interest (ROIs) to Understand the Tracts
- Getting started with pyAFQ - GroupAFQ
- Tutorials: Getting started
- How To
- How to install
pyAFQ - How to get help using pyAFQ
- How to cite our work
- Organizing your data
- Re-running pyAFQ
- How to add custom tissue properties from another pipeline
- Tractography from other pipelines
- Matlab AFQ to Python AFQ conversion
- The pyAFQ docker image
- The pyAFQ singularity image
- The pyAFQ Image API
- Tractography Parameters
- Segmentation Parameters
- Cleaning Parameters
- How to examples
- How to add new bundles into pyAFQ (Acoustic Radiations Example)
- Creating tract density maps of callosal bundles
- How to use Free water DTI
- BabyAFQ : tractometry for infant dMRI data
- Delineating cerebellar peduncles
- Using cloudknot to run pyAFQ on AWS batch:
- AFQ with HCP data
- How to add new bundles into pyAFQ (Optic Radiations Example)
- How to track the Optic Tract and Posterior Optic Nerve in pyAFQ
- Understanding the different stages of tractometry with videos
- Imports
- Get data from HBN POD2
- Visualize the processed dMRI data
- Visualizing whole-brain tractography
- Visualize the streamlines
- Whole brain with waypoints
- Define the bundles
- Visualize the arcuate bundle
- Clean bundle
- Show the values of tissue properties along the bundle
- Core of the bundle and tract profile
- Core of all bundles and their tract profiles
- Tract profiles as a table
- How to use TRX in pyAFQ
- Running pyAFQ using the GPU for tractography
- Running pyAFQ 2.x defaults in pyAFQ 3.x
- Using RecoBundles for bundle recognition
- Using Subject Space ROIs from Freesurfer
- How to segment out only some bundles
- How to install
- Explanations
- Reference Documentation
- API Reference
- AFQ
- Submodules
- AFQ.api
- Submodules
- AFQ.api.bundle_dict
- Classes
- Functions
- Module Contents
default_bd()baby_bd()callosal_bd()reco_bd()cerebellar_bd()BundleDictBundleDict.resample_toBundleDict.resample_subject_toBundleDict.keep_in_memoryBundleDict.citationsBundleDict._dictBundleDict.bundle_namesBundleDict.loggerBundleDict.__print__()BundleDict._use_bids_info()BundleDict._cond_load()BundleDict.get_b_info()BundleDict.relax_cleaning()BundleDict.__getitem__()BundleDict.__setitem__()BundleDict.__len__()BundleDict.__delitem__()BundleDict.__iter__()BundleDict.copy()BundleDict.apply_to_rois()BundleDict._cond_load_bundle()BundleDict.is_bundle_in_template()BundleDict._roi_transform_helper()BundleDict.transform_rois()BundleDict.__add__()
- AFQ.api.group
- Classes
- Module Contents
GroupAFQGroupAFQ.loggerGroupAFQ.parallel_paramsGroupAFQ.plans_dictGroupAFQ.subjectsGroupAFQ.sessionsGroupAFQ.valid_sub_listGroupAFQ.valid_ses_listGroupAFQ.pAFQ_listGroupAFQ.pAFQ_inputs_listGroupAFQ.kwargsGroupAFQ.from_qsiprep()GroupAFQ.combine_profiles()GroupAFQ.get_streamlines_json()GroupAFQ.export()GroupAFQ.export_up_to()GroupAFQ.export_all()GroupAFQ.delete_full_tractogram()GroupAFQ.cmd_outputs()GroupAFQ.clobberGroupAFQ.make_all_participant_montages()GroupAFQ.group_montage()GroupAFQ.combine_bundle()GroupAFQ.upload_to_s3()GroupAFQ.export_group_density()GroupAFQ.assemble_AFQ_browser()
- AFQ.api.participant
- Classes
- Module Contents
ParticipantAFQParticipantAFQ.loggerParticipantAFQ.og_kwargsParticipantAFQ.kwargsParticipantAFQ.make_workflow()ParticipantAFQ.export()ParticipantAFQ.export_up_to()ParticipantAFQ.export_all()ParticipantAFQ.delete_full_tractogram()ParticipantAFQ.participant_montage()ParticipantAFQ.cmd_outputs()ParticipantAFQ.clobber
- AFQ.api.utils
- AFQ.api.bundle_dict
- Submodules
- AFQ.data
- Submodules
- AFQ.data.fetch
- Attributes
- Functions
- Module Contents
fetch_callosum_templatesread_callosum_templates()fetch_synthseg_modelsfetch_babyseg_modelsfetch_multiaxial_modelsfetch_brainchop_modelsfetch_templatesread_templates()fetch_or_templatesread_or_templates()fetch_stanford_hardi_tractographyread_stanford_hardi_tractography()organize_stanford_data()fetch_stanford_hardi_lv1
- AFQ.data.utils
- AFQ.data.fetch
- Submodules
- AFQ.definitions
- AFQ.models
- AFQ.nn
- Submodules
- AFQ.nn.babyseg
- Attributes
- Classes
- Functions
- Module Contents
loggerBabySegLabelsBabySegLabels.BACKGROUNDBabySegLabels.LEFT_CEREBRAL_WHITE_MATTERBabySegLabels.LEFT_CEREBRAL_CORTEXBabySegLabels.LEFT_LATERAL_VENTRICLEBabySegLabels.LEFT_CEREBELLUM_CORTEXBabySegLabels.LEFT_THALAMUSBabySegLabels.LEFT_CAUDATEBabySegLabels.BRAIN_STEMBabySegLabels.LEFT_HIPPOCAMPUSBabySegLabels.LEFT_AMYGDALABabySegLabels.LEFT_VENTRAL_DCBabySegLabels.RIGHT_CEREBRAL_WHITE_MATTERBabySegLabels.RIGHT_CEREBRAL_CORTEXBabySegLabels.RIGHT_LATERAL_VENTRICLEBabySegLabels.RIGHT_CEREBELLUM_CORTEXBabySegLabels.RIGHT_THALAMUSBabySegLabels.RIGHT_CAUDATEBabySegLabels.RIGHT_HIPPOCAMPUSBabySegLabels.RIGHT_AMYGDALABabySegLabels.RIGHT_VENTRAL_DCBabySegLabels.LEFT_BASAL_GANGLIABabySegLabels.RIGHT_BASAL_GANGLIA
_get_model()run_babyseg()pve_from_babyseg()
- AFQ.nn.brainchop
- AFQ.nn.multiaxial
- AFQ.nn.synthseg
- Classes
- Functions
- Module Contents
SynthSegLabelsSynthSegLabels.BACKGROUNDSynthSegLabels.LEFT_CEREBRAL_WHITE_MATTERSynthSegLabels.LEFT_CEREBRAL_CORTEXSynthSegLabels.LEFT_LATERAL_VENTRICLESynthSegLabels.LEFT_INFERIOR_LATERAL_VENTRICLESynthSegLabels.LEFT_CEREBELLUM_WHITE_MATTERSynthSegLabels.LEFT_CEREBELLUM_CORTEXSynthSegLabels.LEFT_THALAMUSSynthSegLabels.LEFT_CAUDATESynthSegLabels.LEFT_PUTAMENSynthSegLabels.LEFT_PALLIDUMSynthSegLabels.THIRD_VENTRICLESynthSegLabels.FOURTH_VENTRICLESynthSegLabels.BRAIN_STEMSynthSegLabels.LEFT_HIPPOCAMPUSSynthSegLabels.LEFT_AMYGDALASynthSegLabels.CSFSynthSegLabels.LEFT_ACCUMBENS_AREASynthSegLabels.LEFT_VENTRAL_DCSynthSegLabels.RIGHT_CEREBRAL_WHITE_MATTERSynthSegLabels.RIGHT_CEREBRAL_CORTEXSynthSegLabels.RIGHT_LATERAL_VENTRICLESynthSegLabels.RIGHT_INFERIOR_LATERAL_VENTRICLESynthSegLabels.RIGHT_CEREBELLUM_WHITE_MATTERSynthSegLabels.RIGHT_CEREBELLUM_CORTEXSynthSegLabels.RIGHT_THALAMUSSynthSegLabels.RIGHT_CAUDATESynthSegLabels.RIGHT_PUTAMENSynthSegLabels.RIGHT_PALLIDUMSynthSegLabels.RIGHT_HIPPOCAMPUSSynthSegLabels.RIGHT_AMYGDALASynthSegLabels.RIGHT_ACCUMBENS_AREASynthSegLabels.RIGHT_VENTRAL_DCSynthSegLabels.BACKGROUND_PARCSynthSegLabels.CTX_LH_BANKSSTSSynthSegLabels.CTX_LH_CAUDALANTERIORCINGULATESynthSegLabels.CTX_LH_CAUDALMIDDLEFRONTALSynthSegLabels.CTX_LH_CUNEUSSynthSegLabels.CTX_LH_ENTORHINALSynthSegLabels.CTX_LH_FUSIFORMSynthSegLabels.CTX_LH_INFERIORPARIETALSynthSegLabels.CTX_LH_INFERIORTEMPORALSynthSegLabels.CTX_LH_ISTHMUSCINGULATESynthSegLabels.CTX_LH_LATERALOCCIPITALSynthSegLabels.CTX_LH_LATERALORBITOFRONTALSynthSegLabels.CTX_LH_LINGUALSynthSegLabels.CTX_LH_MEDIALORBITOFRONTALSynthSegLabels.CTX_LH_MIDDLETEMPORALSynthSegLabels.CTX_LH_PARAHIPPOCAMPALSynthSegLabels.CTX_LH_PARACENTRALSynthSegLabels.CTX_LH_PARSOPERCULARISSynthSegLabels.CTX_LH_PARSORBITALISSynthSegLabels.CTX_LH_PARSTRIANGULARISSynthSegLabels.CTX_LH_PERICALCARINESynthSegLabels.CTX_LH_POSTCENTRALSynthSegLabels.CTX_LH_POSTERIORCINGULATESynthSegLabels.CTX_LH_PRECENTRALSynthSegLabels.CTX_LH_PRECUNEUSSynthSegLabels.CTX_LH_ROSTRALANTERIORCINGULATESynthSegLabels.CTX_LH_ROSTRALMIDDLEFRONTALSynthSegLabels.CTX_LH_SUPERIORFRONTALSynthSegLabels.CTX_LH_SUPERIORPARIETALSynthSegLabels.CTX_LH_SUPERIORTEMPORALSynthSegLabels.CTX_LH_SUPRAMARGINALSynthSegLabels.CTX_LH_FRONTALPOLESynthSegLabels.CTX_LH_TEMPORALPOLESynthSegLabels.CTX_LH_TRANSVERSETEMPORALSynthSegLabels.CTX_LH_INSULASynthSegLabels.CTX_RH_BANKSSTSSynthSegLabels.CTX_RH_CAUDALANTERIORCINGULATESynthSegLabels.CTX_RH_CAUDALMIDDLEFRONTALSynthSegLabels.CTX_RH_CUNEUSSynthSegLabels.CTX_RH_ENTORHINALSynthSegLabels.CTX_RH_FUSIFORMSynthSegLabels.CTX_RH_INFERIORPARIETALSynthSegLabels.CTX_RH_INFERIORTEMPORALSynthSegLabels.CTX_RH_ISTHMUSCINGULATESynthSegLabels.CTX_RH_LATERALOCCIPITALSynthSegLabels.CTX_RH_LATERALORBITOFRONTALSynthSegLabels.CTX_RH_LINGUALSynthSegLabels.CTX_RH_MEDIALORBITOFRONTALSynthSegLabels.CTX_RH_MIDDLETEMPORALSynthSegLabels.CTX_RH_PARAHIPPOCAMPALSynthSegLabels.CTX_RH_PARACENTRALSynthSegLabels.CTX_RH_PARSOPERCULARISSynthSegLabels.CTX_RH_PARSORBITALISSynthSegLabels.CTX_RH_PARSTRIANGULARISSynthSegLabels.CTX_RH_PERICALCARINESynthSegLabels.CTX_RH_POSTCENTRALSynthSegLabels.CTX_RH_POSTERIORCINGULATESynthSegLabels.CTX_RH_PRECENTRALSynthSegLabels.CTX_RH_PRECUNEUSSynthSegLabels.CTX_RH_ROSTRALANTERIORCINGULATESynthSegLabels.CTX_RH_ROSTRALMIDDLEFRONTALSynthSegLabels.CTX_RH_SUPERIORFRONTALSynthSegLabels.CTX_RH_SUPERIORPARIETALSynthSegLabels.CTX_RH_SUPERIORTEMPORALSynthSegLabels.CTX_RH_SUPRAMARGINALSynthSegLabels.CTX_RH_FRONTALPOLESynthSegLabels.CTX_RH_TEMPORALPOLESynthSegLabels.CTX_RH_TRANSVERSETEMPORALSynthSegLabels.CTX_RH_INSULASynthSegLabels.LEFT_HYPOTHALAMUSSynthSegLabels.RIGHT_HYPOTHALAMUS
run_synthseg()
- AFQ.nn.utils
- AFQ.nn.babyseg
- Submodules
- AFQ.recognition
- Submodules
- AFQ.recognition.cleaning
- AFQ.recognition.clustering
- AFQ.recognition.criteria
- Attributes
- Functions
- Module Contents
criteria_order_chunk_localcriteria_order_pre_other_bundlescriteria_order_post_other_bundlesvalid_noncriterionloggerprob_map()cross_midline()start()end()length()endpoint_dists()primary_axis()include()curvature()exclude()recobundles()qb_thresh()clean_by_other_bundle()orient_mahal()isolation_forest()mahalanobis()_prepare_bundle_def()_validate_criteria()_run_chunk_local()_run_global_phase()recognize_bundles()
- AFQ.recognition.curvature
- AFQ.recognition.other_bundles
- AFQ.recognition.preprocess
- AFQ.recognition.recognize
- AFQ.recognition.roi
- AFQ.recognition.sparse_decisions
- AFQ.recognition.utils
- Attributes
- Classes
- Functions
- Module Contents
axes_dictmanual_orient_sls()tolerance_mm_to_vox()flip_sls()cut_sls_by_closest()orient_by_streamline()resample_tg()SlsBeingRecognizedSlsBeingRecognized.oriented_yetSlsBeingRecognized.selected_fiber_idxsSlsBeingRecognized.sls_flippedSlsBeingRecognized.start_timeSlsBeingRecognized.save_intermediatesSlsBeingRecognized.b_nameSlsBeingRecognized.ref_slsSlsBeingRecognized.refSlsBeingRecognized.n_roiSlsBeingRecognized.initiate_selection()SlsBeingRecognized.select()SlsBeingRecognized.get_selected_sls()SlsBeingRecognized.reorient()SlsBeingRecognized.__bool__()SlsBeingRecognized.__len__()SlsBeingRecognized.copy()SlsBeingRecognized.export_selected()SlsBeingRecognized.from_selected()
- Submodules
- AFQ.registration
- AFQ.tasks
- Submodules
- AFQ.tasks.data
- Attributes
- Functions
- Module Contents
loggerDIPY_GH_or_to_text()get_data_gtab()b0()t1w_over_b0()t1w_over_log_b0()b0_mask()dti_fit()dti_params()fwdti_fit()fwdti_params()dki_fit()dki_params()msdki_fit()msdki_params()msdki_msd()msdki_msk()csd_params()csd_aodf()csd_aodf_asi()csd_aodf_opm()anisotropic_power_map()csd_anisotropic_index()gq()rumba_params()opdt_params()opdt_pmap()opdt_ai()csa_params()csa_pmap()csa_ai()fwdti_fa()fwdti_md()fwdti_fwf()dti_fa()dti_lt()dti_cfa()dti_pdd()dti_md()dti_ga()dti_rd()dti_ad()dki_kt()dki_lt()dki_cfa()dki_fa()dki_md()dki_awf()dki_mk()dki_kfa()dki_cl()dki_cp()dki_cs()dki_ga()dki_rd()dki_ad()dki_rk()dki_ak()brain_mask()get_bundle_dict()get_data_plan()
- AFQ.tasks.decorators
- AFQ.tasks.mapping
- AFQ.tasks.segmentation
- AFQ.tasks.structural
- AFQ.tasks.tissue
- AFQ.tasks.tractography
- AFQ.tasks.utils
- AFQ.tasks.viz
- AFQ.tasks.data
- Submodules
- AFQ.tractography
- AFQ.utils
- Submodules
- AFQ.viz
- AFQ.api
- Attributes
- Package Contents
- Submodules
- AFQ
- Defining Custom Bundle Dictionaries
- Major Fiber Tracts
- Tissue Properties in pyAFQ
- The pyAFQ API methods
- The pyAFQ API optional arguments
- Visualization Backends
- Fury Dockerfile for Cloudknot
- The pyAFQ Mapping API
- The pyAFQ CLI
- API Reference