AIFB DataSet
AIFB DataSet is a Semantic Web (RDF) dataset used as a benchmark in data mining. The dataset consists of a single approximately 3 megabyte large file. It records the organizational structure of AIFB at the University of Karlsruhe.
Prerequisites
editGet the data
editThe dataset is distributed from https://figshare.com/articles/AIFB_DataSet/745364.
Get context
editThe dataset was used in Kernel Methods for Mining Instance Data in Ontologies. Find and read the part of the dataset on page 10.
Python
editSetup a Python environment with rdflib installed and load the AIFB file and count the number of times the "affiliation" property is used:
from rdflib import Graph, URIRef
g = Graph()
g.load('aifbfixed_complete.n3', format='n3')
len(list(g.triples((None, URIRef("http://swrc.ontoware.org/ontology#affiliation"), None))))
The URI for the affiliations can be obtained with:
affiliations = g.triples((None, URIRef("http://swrc.ontoware.org/ontology#affiliation"), None))
groups = set(affiliation[2] for affiliation in affiliations)
How many different affiliations are there?
Find the name of the affiliations via "http://swrc.ontoware.org/ontology#name".