def check_experiment_setup(experiment_setup_dict, component_inchikey_dict):
    'Validates experiment setup for given lists of inchikeys.'
    all_inchikeys_in_library = (combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_OBSERVED_KEY], component_inchikey_dict) + combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_PREDICTED_KEY], component_inchikey_dict))
    all_inchikeys_in_use = []
    for kwarg in component_inchikey_dict.keys():
        all_inchikeys_in_use.extend(component_inchikey_dict[kwarg])
    assert (set(all_inchikeys_in_use) == set(all_inchikeys_in_library)), 'Inchikeys in library for library matching does not match full dataset.'
    assert set(combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_QUERY_KEY], component_inchikey_dict)).issubset(set(all_inchikeys_in_library)), 'Inchikeys in query set for library matching notfound in library.'
Validates experiment setup for given lists of inchikeys.
def check_experiment_setup(experiment_setup_dict, component_inchikey_dict):
    
    all_inchikeys_in_library = (combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_OBSERVED_KEY], component_inchikey_dict) + combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_PREDICTED_KEY], component_inchikey_dict))
    all_inchikeys_in_use = []
    for kwarg in component_inchikey_dict.keys():
        all_inchikeys_in_use.extend(component_inchikey_dict[kwarg])
    assert (set(all_inchikeys_in_use) == set(all_inchikeys_in_library)), 'Inchikeys in library for library matching does not match full dataset.'
    assert set(combine_inchikey_sets(experiment_setup_dict[ds_constants.LIBRARY_MATCHING_QUERY_KEY], component_inchikey_dict)).issubset(set(all_inchikeys_in_library)), 'Inchikeys in query set for library matching notfound in library.'