下载并设置 dbpedia 转储
我正在尝试将 DBpedia 转储下载到本地计算机,以便我可以在本地进行查询。查看下载后,我有一些问题:
- 我到底要下载什么?
- 如何将转储加载到我的 RAM 中以便更快地得到结果?
注意:我使用 dotNetRDF 库来执行查询。
I am trying to download the DBpedia dump to my local computer so that I can do queries locally. After taking a look at the Downloads I have some questions:
- What exactly do I download?
- How to load the dump into my RAM so that the results come faster?
NOTE: I am using the dotNetRDF libary to do the queries.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
nt 文件是您需要下载到计算机中的 N-Triples,一个类别中有如此多 nt 文件的原因是它们是按语言分类的。
以下代码添加到您的 .NET 项目中
下载 nt 文件后,您需要在引用 dotNetRDF dll后将 您已经加载了 nt 文件,请注意,英文 dbpedia 转储非常大,您可能需要非常大的 RAM 来加载三重存储。
如果你想做一个查询,只需添加这行代码:
还有其他类似 TripleStore 的类,如 DiskDemandTripleStore 、 OnDemandTripleStore 、 SqlTripleStore 等>,
WebDemandTripleStore
参见 文档 有关这些“和其他”类的更多信息the nt files are the N-Triples you need to download into your computer, the reason for being so many nt files for one category is that they're categorized by language.
after downloading the nt files, you need to add the following code to your .NET project after referencing the dotNetRDF dlls
Now you've loaded the nt files, note that the english dbpedia dump is very large , you probably need very big RAM to load the triple store.
if you want to do a query, just add this line of code:
There're also another classes like TripleStore, like
DiskDemandTripleStore
,OnDemandTripleStore
,SqlTripleStore
,WebDemandTripleStore
see the documentation for more info about these 'And other' Classes