cobra_db.scripts.stage_2_group_studies

Module Contents

Functions

proto_study_generator(connector_kwargs)

get_tag(d, keyword)

set_union(dicom_tags, keyword)

group_study(→ cobra_db.model.RadiologicalStudy)

Takes the dict of many ImageMetadata instances.

process_study_batch(args)

main(connector_kwargs, project_name)

main_multiproc(connector_kwargs, n_proc, project)

cobra_db.scripts.stage_2_group_studies.proto_study_generator(connector_kwargs)[source]
cobra_db.scripts.stage_2_group_studies.get_tag(d, keyword)[source]
cobra_db.scripts.stage_2_group_studies.set_union(dicom_tags: List[dict], keyword)[source]
cobra_db.scripts.stage_2_group_studies.group_study(images: List[dict], project_name: str) cobra_db.model.RadiologicalStudy[source]

Takes the dict of many ImageMetadata instances. Obtains the shared dicom_tags and extract more information to put it in the root of the document.

Parameters:
  • images – List of dictionaries from the ImageMetadata collection

  • project_name – Project to which this study belongs.

cobra_db.scripts.stage_2_group_studies.process_study_batch(args: Tuple[List[dict], dict, str])[source]
cobra_db.scripts.stage_2_group_studies.main(connector_kwargs, project_name)[source]
cobra_db.scripts.stage_2_group_studies.main_multiproc(connector_kwargs, n_proc, project)[source]