load_pkg_chemical_hierarchy
- load_pkg_chemical_hierarchy(file_path: str | Path = 'scratch/wikidata_classes_taxonomy.tsv') dict[str, list[str]][source]
Load chemical class hierarchy from a TSV file.
The file should have at least 3 columns, where: - Column 2 (index 1): Class URI - Column 3 (index 2): Parent URI
- Parameters:
file_path – Path to the TSV file containing hierarchy data.
- Returns:
Dictionary mapping parent class URIs to lists of child class URIs.
- Raises:
DataLoadingError – If the file cannot be read or parsed.