2.2. QDPi1
- class pharmaforge.recipes.QDPi1.QDPi1Recipe(input_dir=None, client='mongodb://localhost:27017/')[source]
Bases:
GeneralRecipe
A subclass of GeneralRecipe to generate the QDPi1 database
Methods
add_field
(collection, field_name, field_value)Add a field to the recipe :param field_name: The name of the field to add :type field_name: str :param field_value: The value of the field to add :type field_value: any
add_field_from_kwargs
()Add a field to the recipe from the kwargs :param field_name: The name of the field to add :type field_name: str :param field_value: The value of the field to add :type field_value: any
clear_db
()Clear the database :param database_name: The name of the database to clear.
Check if the collections are present in the database :param None:
open_client
(client)Add the recipe to the client :param client: The MongoDB client to add the recipe to :type client: MongoClient
pprint_one_entry
()Pretty print one entry from the database :param None:
process_hdf5
(input_dir)Process the HDF5 files in the input directory :param input_dir: The directory containing the HDF5 files to process :type input_dir: str
check_collections