Python API¶
-
class
bob.db.fargo.
Database
(original_directory=None, original_extension=None, annotation_directory=None, annotation_extension=None, protocol='mc-rgb')[source]¶ Bases:
bob.db.base.SQLiteDatabase
Class representing the database
See parent class :py:class:bob.db.base.SQLiteDatabase for more details …
-
property
modalities
¶
-
groups
(protocol=None)[source]¶ Returns the names of all registered groups
- Parameters
protocol (str) – ignored, since the group are the same across protocols.
-
clients
(protocol=None, groups=None)[source]¶ Returns a set of clients for the specific query by the user.
-
models
(protocol=None, groups=None)[source]¶ Returns a set of models for the specific query by the user.
- Parameters
protocol – Ignored since the models are identical for all protocols.
groups – The groups to which the subjects attached to the models belong
- Returns
A list containing all the models which have the given properties.
- Return type
lst
-
model_ids
(protocol=None, groups=None)[source]¶ Returns a set of models ids for the specific query by the user.
- Parameters
protocol – Ignored since the models are identical for all protocols.
groups – The groups to which the subjects attached to the models belong
- Returns
A list containing all the models ids which have the given properties.
- Return type
lst
-
client
(id)[source]¶ Returns the client object of the specified id.
- Parameters
id (int) – The client id.
- Raises
Error: – if the client does not exist.
-
objects
(protocol=None, purposes=None, model_ids=None, groups=None, modality=None)[source]¶ Returns a set of Files for the specific query by the user.
- Parameters
protocol (str) – One of the FARGO protocols.
purposes (str or tuple of str) – The purposes required to be retrieved (‘enroll’, ‘probe’, ‘train’) or a tuple with several of them. If ‘None’ is given (this is the default), it is considered the same as a tuple with all possible values. This field is ignored for the data from the “world” group.
model_ids (int or tuple of int) – Only retrieves the files for the provided list of model ids. If ‘None’ is given, no filter over the model_ids is performed.
groups (str or tuple of str) – One of the groups (‘dev’, ‘eval’, ‘world’) or a tuple with several of them. If ‘None’ is given (this is the default), it is considered the same as a tuple with all possible values.
modality (str or tuple) – One of the three modalities ‘rgb’, ‘nir’ and ‘depth’
- Returns
A list of files which have the given properties.
- Return type
lst
-
property