ontolearn.nces_utils

NCES utils.

Classes

SimpleSolution

Functions

sample_examples(pos, neg, num_ex)

try_get_embs(pos, neg, embeddings, num_examples)

Depending on the KGE model, some individuals do not get assigned to any embedding during training. This function filters out such individuals from the provided positive/negative examples. It also

generate_training_data(kb_path[, max_num_lps, ...])

Module Contents

class ontolearn.nces_utils.SimpleSolution(vocab, atomic_concept_names)[source]
name = 'SimpleSolution'
atomic_concept_names
tokenizer
predict(expression: str)[source]
ontolearn.nces_utils.sample_examples(pos, neg, num_ex)[source]
ontolearn.nces_utils.try_get_embs(pos, neg, embeddings, num_examples)[source]

Depending on the KGE model, some individuals do not get assigned to any embedding during training. This function filters out such individuals from the provided positive/negative examples. It also

ontolearn.nces_utils.generate_training_data(kb_path, max_num_lps=1000, refinement_expressivity=0.2, refs_sample_size=50, beyond_alc=True, storage_path=None)[source]