def METHOD_NAME(cls, event_data: NodeData) -> Optional["CalculatedHashes"]:
    hashes = event_data.get("hashes")
    hierarchical_hashes = event_data.get("hierarchical_hashes") or []
    tree_labels = event_data.get("hierarchical_tree_labels") or []
    if hashes is not None:
        return cls(
            hashes=hashes, hierarchical_hashes=hierarchical_hashes, tree_labels=tree_labels
        )
    return None