populse_mia.data_manager¶
Module to handle the projects and their database.
Module Attributes
Field type for string values (maps to Python |
|
Field type for integer values (maps to Python |
|
Field type for floating-point values (maps to Python |
|
Field type for boolean values (maps to Python |
|
Field type for date values (maps to |
|
Field type for datetime values (maps to |
|
Field type for time values (maps to |
|
Field type for JSON objects (maps to Python |
|
Field type for lists of string values (maps to |
|
Field type for lists of integer values (maps to |
|
Field type for lists of floating-point values (maps to |
|
Field type for lists of boolean values (maps to |
|
Field type for lists of date values (maps to |
|
Field type for lists of datetime values (maps to |
|
Field type for lists of time values (maps to |
|
Field type for lists of JSON objects (maps to |
|
Set of all supported field types (both scalar and list variants). |
|
Mapping from V2 string field type names to their corresponding V3 Python types. |
|
Tag unit for milliseconds. |
|
Tag unit for millimetres. |
|
Tag unit for degrees. |
|
Tag unit for Hz per pixel. |
|
Tag unit for megahertz. |
|
List of all supported tag units. |
|
Name of the collection storing the current state of the database. |
|
Name of the collection storing the initial state of the database at import time. |
|
Name of the collection storing brick (pipeline process) records. |
|
Name of the collection storing the full pipeline execution history. |
|
Name of the internal collection storing field metadata and attributes. |
|
Tag origin indicating the tag is a built-in MIA tag. |
|
Tag origin indicating the tag was created by the user. |
|
Tag name for the file checksum, used to detect file modifications. |
|
Tag name for the document type (e.g. Scan, Matrix, Text). |
|
Tag name for the experimental type of the document. |
|
Tag name for the file name of the document. |
|
Tag name for the list of brick IDs that produced the document. |
|
Tag name for the full pipeline execution history associated with the document. |
|
Dictionary of clinical tag names and their descriptions. |
|
Brick field name for the unique identifier of a brick. |
|
Brick field name for the name of the brick (pipeline process). |
|
Brick field name for the list of input parameters of the brick. |
|
Brick field name for the list of output parameters of the brick. |
|
Brick field name for the initialisation status of the brick. |
|
Brick field name for the execution status of the brick. |
|
Brick field name for the timestamp of the brick initialisation. |
|
Brick field name for the timestamp of the brick execution. |
|
History field name for the unique identifier of a history record. |
|
History field name for the XML serialisation of the pipeline. |
|
History field name for the list of brick UUIDs in the history record. |
|
Document type for b-vector files used in diffusion MRI. |
|
Document type for b-value files used in diffusion MRI. |
|
Document type for combined b-vector/b-value files in MRtrix format. |
|
Document type for NIfTI scan files. |
|
Document type for matrix files. |
|
Document type for plain text files. |
|
Document type for files with an unrecognised or unsupported format. |
|
Placeholder string displayed when a tag has no value defined for a document. |
- populse_mia.data_manager.FIELD_TYPE_FLOAT¶
Field type for floating-point values (maps to Python
float).
- populse_mia.data_manager.FIELD_TYPE_DATE¶
Field type for date values (maps to
datetime.date).
- populse_mia.data_manager.FIELD_TYPE_DATETIME¶
Field type for datetime values (maps to
datetime.datetime).
- populse_mia.data_manager.FIELD_TYPE_TIME¶
Field type for time values (maps to
datetime.time).
- populse_mia.data_manager.FIELD_TYPE_LIST_STRING¶
Field type for lists of string values (maps to
listofstr).
- populse_mia.data_manager.FIELD_TYPE_LIST_INTEGER¶
Field type for lists of integer values (maps to
listofint).
- populse_mia.data_manager.FIELD_TYPE_LIST_FLOAT¶
Field type for lists of floating-point values (maps to
listoffloat).
- populse_mia.data_manager.FIELD_TYPE_LIST_BOOLEAN¶
Field type for lists of boolean values (maps to
listofbool).
- populse_mia.data_manager.FIELD_TYPE_LIST_DATE¶
Field type for lists of date values (maps to
listofdatetime.date).
- populse_mia.data_manager.FIELD_TYPE_LIST_DATETIME¶
Field type for lists of datetime values (maps to
listofdatetime.datetime).
- populse_mia.data_manager.FIELD_TYPE_LIST_TIME¶
Field type for lists of time values (maps to
listofdatetime.time).
- populse_mia.data_manager.FIELD_TYPE_LIST_JSON¶
Field type for lists of JSON objects (maps to
listofdict).
- populse_mia.data_manager.ALL_TYPES = {<class 'bool'>, <class 'datetime.date'>, <class 'datetime.datetime'>, <class 'datetime.time'>, <class 'dict'>, <class 'float'>, <class 'int'>, <class 'str'>, list[bool], list[datetime.date], list[datetime.datetime], list[datetime.time], list[dict], list[float], list[int], list[str]}¶
Set of all supported field types (both scalar and list variants).
- populse_mia.data_manager.FIELD_TYPE_MAPPING = {'boolean': <class 'bool'>, 'date': <class 'datetime.date'>, 'datetime': <class 'datetime.datetime'>, 'float': <class 'float'>, 'int': <class 'int'>, 'json': <class 'dict'>, 'list_boolean': list[bool], 'list_date': list[datetime.date], 'list_datetime': list[datetime.datetime], 'list_float': list[float], 'list_int': list[int], 'list_json': list[dict], 'list_string': list[str], 'list_time': list[datetime.time], 'string': <class 'str'>, 'time': <class 'datetime.time'>}¶
Mapping from V2 string field type names to their corresponding V3 Python types. Used for backwards compatibility when reading older database formats.
- populse_mia.data_manager.TAG_UNIT_MS = 'ms'¶
Tag unit for milliseconds.
- populse_mia.data_manager.TAG_UNIT_MM = 'mm'¶
Tag unit for millimetres.
- populse_mia.data_manager.TAG_UNIT_DEGREE = 'degree'¶
Tag unit for degrees.
- populse_mia.data_manager.TAG_UNIT_HZPIXEL = 'Hz/pixel'¶
Tag unit for Hz per pixel.
- populse_mia.data_manager.TAG_UNIT_MHZ = 'MHz'¶
Tag unit for megahertz.
- populse_mia.data_manager.ALL_UNITS = ['ms', 'mm', 'degree', 'Hz/pixel', 'MHz']¶
List of all supported tag units.
- populse_mia.data_manager.COLLECTION_CURRENT = 'current'¶
Name of the collection storing the current state of the database.
- populse_mia.data_manager.COLLECTION_INITIAL = 'initial'¶
Name of the collection storing the initial state of the database at import time.
- populse_mia.data_manager.COLLECTION_BRICK = 'brick'¶
Name of the collection storing brick (pipeline process) records.
- populse_mia.data_manager.COLLECTION_HISTORY = 'history'¶
Name of the collection storing the full pipeline execution history.
- populse_mia.data_manager.FIELD_ATTRIBUTES_COLLECTION = 'mia_field_attributes'¶
Name of the internal collection storing field metadata and attributes.
- populse_mia.data_manager.TAG_ORIGIN_BUILTIN = 'builtin'¶
Tag origin indicating the tag is a built-in MIA tag.
- populse_mia.data_manager.TAG_ORIGIN_USER = 'user'¶
Tag origin indicating the tag was created by the user.
- populse_mia.data_manager.TAG_CHECKSUM = 'Checksum'¶
Tag name for the file checksum, used to detect file modifications.
- populse_mia.data_manager.TAG_TYPE = 'Type'¶
Tag name for the document type (e.g. Scan, Matrix, Text).
- populse_mia.data_manager.TAG_EXP_TYPE = 'Exp Type'¶
Tag name for the experimental type of the document.
- populse_mia.data_manager.TAG_FILENAME = 'FileName'¶
Tag name for the file name of the document.
- populse_mia.data_manager.TAG_BRICKS = 'History'¶
Tag name for the list of brick IDs that produced the document.
- populse_mia.data_manager.TAG_HISTORY = 'Full history'¶
Tag name for the full pipeline execution history associated with the document.
- populse_mia.data_manager.CLINICAL_TAGS = {'Age': "patient's age", 'Institution': 'site where the NMR spectrometer is installed', 'MagneticFieldStrength': 'nominal field strength of MR magnet in Tesla', 'Manufacturer': 'manufacturer of the MRI spectrometer', "Manufacturer's Model": "manufacturer's model name of the MRI spectrometer", 'Message': 'brief message about the patient', 'Pathology': "patient's pathology", 'PatientRef': "patient's anonymous reference", 'Sex': "patient's gender", 'SoftwareVersions': 'version of the software used to acquire the data'}¶
Dictionary of clinical tag names and their descriptions. These tags store patient and acquisition metadata.
- populse_mia.data_manager.BRICK_ID = 'ID'¶
Brick field name for the unique identifier of a brick.
- populse_mia.data_manager.BRICK_NAME = 'Name'¶
Brick field name for the name of the brick (pipeline process).
- populse_mia.data_manager.BRICK_INPUTS = 'Input(s)'¶
Brick field name for the list of input parameters of the brick.
- populse_mia.data_manager.BRICK_OUTPUTS = 'Output(s)'¶
Brick field name for the list of output parameters of the brick.
- populse_mia.data_manager.BRICK_INIT = 'Init'¶
Brick field name for the initialisation status of the brick.
- populse_mia.data_manager.BRICK_EXEC = 'Exec'¶
Brick field name for the execution status of the brick.
- populse_mia.data_manager.BRICK_INIT_TIME = 'Init Time'¶
Brick field name for the timestamp of the brick initialisation.
- populse_mia.data_manager.BRICK_EXEC_TIME = 'Exec Time'¶
Brick field name for the timestamp of the brick execution.
- populse_mia.data_manager.HISTORY_ID = 'ID'¶
History field name for the unique identifier of a history record.
- populse_mia.data_manager.HISTORY_PIPELINE = 'Pipeline xml'¶
History field name for the XML serialisation of the pipeline.
- populse_mia.data_manager.HISTORY_BRICKS = 'Bricks uuid'¶
History field name for the list of brick UUIDs in the history record.
- populse_mia.data_manager.TYPE_BVEC = 'Bvec'¶
Document type for b-vector files used in diffusion MRI.
- populse_mia.data_manager.TYPE_BVAL = 'Bval'¶
Document type for b-value files used in diffusion MRI.
- populse_mia.data_manager.TYPE_BVEC_BVAL = 'Bvec_bval_MRTRIX'¶
Document type for combined b-vector/b-value files in MRtrix format.
- populse_mia.data_manager.TYPE_NII = 'Scan'¶
Document type for NIfTI scan files.
- populse_mia.data_manager.TYPE_MAT = 'Matrix'¶
Document type for matrix files.
- populse_mia.data_manager.TYPE_TXT = 'Text'¶
Document type for plain text files.
- populse_mia.data_manager.TYPE_UNKNOWN = 'Unknown'¶
Document type for files with an unrecognised or unsupported format.
- populse_mia.data_manager.NOT_DEFINED_VALUE = '*Not Defined*'¶
Placeholder string displayed when a tag has no value defined for a document.
Modules
This module provides utilities for tracking, retrieving, and reconstructing the processing history of data files within the Mia framework. |
|
Module for importing MRI scan data from MRIFileManager into a Mia project. |
|
Mia Database Interaction Module |
|
Mia Filter Module |
|
Mia Project Module |
|
Mia Saved Projects Module |