早上好,我正在编写一个可以管理本体的java类,特别是我想找到所有的属性(名称、子类、超类、ecc.)一个OWLClass,但我无法尝试执行隐士,我也不明白为什么。我使用Eclipse项目,pom文件中的依赖项是从隐士示例中复制的,OWLapi依赖项也是如此。
java控制台中的错误是:
Exception in thread "main" java.lang.NullPointerException
at org.semanticweb.HermiT.Reasoner.<init>(Reasoner.java:210)
at org.semanti
对于我的大学,我正在学习RDF/OWL/SPARQL。我正在尝试构建一个利用自动分类的web应用程序,我用Protege开发了本体。现在我有了一个类智能手机和一个子类Fast_Smartphone,它的等效属性设置为:
Smartphone
and (hasCores some integer[>=4])
现在,当我转到DL查询选项卡并选择Fast_smartphone类的实例时,它成功地显示了所有作为智能手机并且具有4个或更多核心的实例。但是,当我到达SPARQL查询选项卡并键入以下查询时:
SELECT *
WHERE { ?x ?y uni:Fast_smartphone}
我一直在研究抗议者,我有个问题。我在本体“”中添加了一个名为aaa的个人,这是我从互联网上下载的。
我将类型断言设置为:绵羊和hasCC值200,其中hasCC是数据属性。然后,在课堂动物中,我创建了两个类:hhh和lll。我把hhh设为等价物,并在那里写到:动物和(hasCC a decimal>= 150) For lll I set: and (hasCC a decimal< 250)
当我运行HermiT推理器时,我看到单个aaa被分类为lll和hhh类。但是,当我将lll和hhh类设置为不相交并运行reasoner时,类不会被分类在类"Nothing“中,例如,
我正在尝试运行LUBM基准测试,但我在分类和推理方面遇到了一些问题。
我使用的文件是:
问题是GraduateStudent和UndergraduateStudent的成员没有被归类为超类Student的成员。
我在Protege 5.0上尝试了Pellet,Hermit和Fact reasoners,都失败了。因此,编号为10的基准SPARQL查询也失败。
#-- Query10
#-- This query differs from Query 6, 7, 8 and 9 in that it only requires the
#-- (implicit) subClassOf re
我正在使用OWL-Api和hermiT推理器,当尝试使用hermiT检索partOf subclasses时,它会返回正确的结果,所以它会返回partOf子类,但它也会返回推断的子类(我不需要)。 以下是用于检索partOf subClasses的函数: //ricerca delle classi che hanno come parti quella attuale
System.out.println("Questa classe è parte di: ");
OWLClassExpression
我在Protege 5.0.0中构建了一个小本体。当我运行Hermit 1.3.8.3推理器时,它输出状态为:
Initializing the reasoner by performing the following steps:
class hierarchy
object property hierarchy
data property hierarchy
class assertions
object property assertions
same individuals
HermiT 1.3.8.3 classified in 97ms
另一方面,当我在同一个本体上运行Fact++
我在使用HermiT推理器库时遇到了问题。
有没有人能理解我做错了什么?
public static void main(String[] args) {
try {
// First, we create an OWLOntologyManager object. The manager will load and
// save ontologies.
OWLOntologyManager manager=OWLManager.createOWLOntologyManager();
// Now, we create
我尝试加载包含bfo.owl的本体(test.owl)。使用的API版本:
OWL-API 3.4.3
隐士1.3.8.4
可以使用Protégé5打开测试本体,但是当我尝试用我的代码加载test.owl时,我得到了下面的错误消息,这是我不理解的。有没有人可以帮助我理解消息并找到加载本体的方法?
org.semanticweb.owlapi.model.UnloadableImportException:无法加载导入的本体:原因:解析时出现问题
Could not parse ontology. Either a suitable parser could not be found, or