qdatalib package

Submodules

qdatalib.mongo_conf module

class qdatalib.mongo_conf.ConfigMongo(confpath=None)[source]

Bases: object

set_connection(client, db, collection)[source]
set_client(client)[source]
set_db(db)[source]
set_collection(collection)[source]
get_client()[source]
get_db()[source]
get_collection()[source]
set_db_local(db_local)[source]
set_db_shared(db_shared)[source]
set_lib_dir(lib_dir)[source]
get_db_local()[source]
get_db_shared()[source]
get_lib_dir()[source]
update_field(section, field, value)[source]
has_or_add_section(section)[source]
write_file()[source]
print_config_file()[source]

qdatalib.tolib module

class qdatalib.tolib.Qdatalib(confpath: Optional[str] = None, mongo_client: Optional[str] = None, mongo_db: Optional[str] = None, mongo_collection: Optional[str] = None, db_local: Optional[str] = None, db_shared: Optional[str] = None, lib_dir: Optional[str] = None)[source]

Bases: object

Class for expporting QCoDeS data stored in SQLite in to other formats and organicing the exported data files using a MongoDB database

[summary]

Parameters
  • mongo_collection (collection, optional) – The collection where information about the files are stored, defaults to None

  • db_local (str, optional) – path to the local QCoDeS SQLite databas, defaults to ‘’

  • db_shared (str, optional) – path to shared QCoDeS SQLite database, defaults to ‘shared.db’

  • lib_dir (str, optional) – path to directory to shared files, defaults to ‘.’

extract_run_into_db_and_catalog_by_id(run_id: int, scientist: str = 'john doe', tag: str = '', note: str = '', dict_exstra={}) None[source]

Extract data seleceted by run_id to shared SQLite database

extract_run_into_nc_and_catalog(run_id: int, scientist: str = 'john doe', tag: str = '', note: str = '', dict_exstra={}) None[source]

Extract data seleceted by run_id to shared netcdf file

extract_run_into_csv_and_catalog(run_id: int, scientist: str = 'john doe', tag: str = '', note: str = '', dict_exstra={}) None[source]

Extract data seleceted by run_id to shared csv file

uploade_to_catalog_by_id(id: int, scientist: str = 'john doe', tag: str = '', note: str = '', dict_exstra={}) None[source]

Upload to catalog

get_data_by_catalog(search_digt: Dict[str, Union[str, float]]) Union[List, qcodes.dataset.data_set.DataSet][source]
get_data_from_nc_by_catalog(search_digt: Dict[str, Union[str, float]]) Union[List, Any][source]
get_data_from_csv_by_catalog(search_digt: Dict[str, Union[str, float]]) Union[List, Any][source]
number_of_results(results: List) Tuple[bool, List][source]
load_by_id_local(id: int) qcodes.dataset.data_set.DataSet[source]
load_shared(guid: str, db_path: str) qcodes.dataset.data_set.DataSet[source]
set_mongo_client(client)[source]
set_mongo_db(db)[source]
set_mongo_collection(collection)[source]
set_db_local(db_local)[source]
set_db_shared(db_shared)[source]
set_lib_dir(lib_dir)[source]

Module contents