-
Notifications
You must be signed in to change notification settings - Fork 5
Data organization
The Flywheel database hierarchy matches a neuroimaging project. The top level is the user's Group; a group typically contains multiple Projects; each project contains multiple Sessions; each session contains multiple Acquisitions; each acquisition contains multiple Files.
The containers are Matlab objects. Each object includes metadata about a Flywheel object, and has methods that perform useful functions. For example, you can
- Display the container's metadata
- Update metadata
- Download or upload content from within the container (e.g., Files, Sessions, Acquisitions)
There are many SDK methods, and one purpose of scitran is to simplify using these methods.
This simple illustration uses a Project to find the files.
project = st.lookup('adni/ADNI: T1');
adniProjectFiles = project.files;
stPrint(adniProjectFiles,'name')
Entry: name.
-----------------------------
1 - ADNI_GeneralProceduresManual.pdf
2 - db_accesslog.csv
The scitran object methods help you perform many simple actions. For example
scitran.lookup('a string') - Returns metadata about a container
scitran.search( ... ) - Searches the database for specific types of metadata
Actions on containers and files can be found using Matlab TAB-completion:
scitran.container<TAB> - Shows all the basic Data Container methods
scitran.file<TAB> - Shows all the basic File methods
scitran.<TAB> - Shows all the scitran methods
One additional data container type, the Collection, is described below. Other objects (Analyses, Gears, and Jobs) are described in the Computational organization section. Most of these containers can include Files.
We use the term info to refer the metadata. There are methods to read and modify the Flywheel Info fields.
st.infoGet - Read metadata from a container or file
st.infoSet - Write metadata on a container or file
Info is organized into various types: notes, tags, and attachments. These are all metadata, but it is useful to have distinguish between certain types of information. You can set notes, tags and attachments with the info* methods.
To reuse data we create a new data container, the Collection. A Collection includes a subset of the sessions, acquisitions that the user selects from the database. In the user interface, a Collection looks like a Project. A Collection as a virtual project based on data reuse.
Scitran has methods to create and delete Collections. These can be found using
scitran.collection<TAB>
All of the Flywheel methods can be invoked from the scitran object. They are available from fw slot, such as
st = scitran('stanfordlabs');
st.fw.getVersion
ans =
VersionOutput with properties:
id: 'version'
appliedFixes: [1×1 struct]
cliVersion: '7.2.0'
database: 63
flywheelRelease: 'emerald.7.0.2'
release: '6.0.5'
>>