def _dict_from_data_collection(self, mapping, data_collection):
        data_dict = {}
        for target_name, search_criteria in mapping.items():
            search_name = search_criteria.get("name", target_name)
            search_tags = search_criteria.get("tags", [])
            target_data = data_collection.get_data(search_name, search_tags)
            if target_data is None:
                message = "Data not found during mapping: name={}, tags={}" \
                        .format(search_name, search_tags)
                raise ValueError(message)
            else:
                data_dict[target_name] = target_data.get_value()
        return data_dict
Resolves a DataCollection to dict mapping.
dataset/ETHPy150Open impactlab/eemeter/eemeter/meter/base.py/MeterBase._dict_from_data_collection