Module Contents#



All Definitions should inherit this.



find_file(bids_layout, path, filters, suffix, session, ...)

Helper function

class AFQ.definitions.utils.Definition[source]#

Bases: object

All Definitions should inherit this. For a given subject and session within the API, the definition is used to create a given image or map. Definitions have an init function which the users uses to specify how they want the definition to behave. The find_path function is called by the AFQ API. The api calls find_path to let the definition find relevant files for the given subject and session.

abstract find_path(bids_layout, from_path, subject, session)[source]#

Uses __init__ in str_for_toml to make string that will instantiate itself. Assumes object will have attributes of same name as __init__ args. This is important for reading/writing definitions as arguments to config files.

AFQ.definitions.utils.find_file(bids_layout, path, filters, suffix, session, subject, extension='.nii.gz')[source]#

Helper function Generic calls to get_nearest to find a file