SPARQLthon/TogoGenomeUpdate/2017 09

提供:TogoWiki

移動: 案内, 検索

目次

エンドポイント

SPARQLthon61 で TogoGenome の SPARQL endpoint を整理した。

これまで

これから

データ量の増大に伴い、バックエンドの ep3, 4, 5 のディスク容量が厳しくなってきたこと、転送に時間がかかること、そもそも開発環境のさらにテスト環境は要らないのではないかということで、4系統から3系統に減らし、本番用にも関わらず /sparl-test の代わりに間違ってよく使われてしまっていた /sparql を TogoGenome アプリには影響しない公開用・テスト用エンドポイントとして位置づける(これまでテスト用に使われていた /sparql-test などはこの alias とする)ことに。

これに合わせ、TogoGenome, TogoStanza の利用するエンドポイントは /saprql-xxx に書き換えてデプロイしなおした。(岡別府・佐藤)

バージョン

  • refseq: release84
  • uniprot: 2017_09

DBファイルサイズ

336G

更新時期

  • 開始: 2017-10-14 22:35

(UniProtのRDF/XMLのデータが変わっていたので1〜2日ほど中断)

  • 終了: 2017-10-25 07:56


obo:so_part_ofのインデックスが効いていないようだったので全データ再ロード

  • 開始 2017-10-31 11:44
  • 終了 2017-11-01 17:40

トリプル数統計

総トリプル数

  • 9,728,316,277 (約97億)

グラフ一覧とトリプル数

グラフURIトリプル数
http://togogenome.org/graph/uniprot5006828154
http://togogenome.org/graph/refseq3229691899
http://togogenome.org/graph/edgestore803076743
http://togogenome.org/graph/assembly_report288963288
http://togogenome.org/graph/tgup152745265
http://togogenome.org/graph/goup123601381
http://togogenome.org/graph/stats82561057
http://togogenome.org/graph/taxonomy23337369
http://togogenome.org/graph/gazetteer7062536
http://togogenome.org/graph/gotax6051839
http://togogenome.org/graph/gold1600208
http://togogenome.org/graph/go1573748
http://togogenome.org/graph/brc914050
http://togogenome.org/graph/tgtax198508
http://togogenome.org/graph/so43060
http://togogenome.org/graph/taxonomy_lite18719
http://togogenome.org/graph/insdc14238
http://togogenome.org/graph/gmo6956
http://togogenome.org/graph/meo4468
http://togogenome.org/graph/meo_descendants4247
http://togogenome.org/graph/pdo_mapping3305
http://togogenome.org/graph/pdo2881
http://togogenome.org/graph/csso2537
http://togogenome.org/graph/mpo1653
http://togogenome.org/graph/mpo_descendants1482
http://togogenome.org/graph/mccv675
http://togogenome.org/graph/faldo232
http://togogenome.org/graph27

データの更新

UniProt

rdf:aboutの記述

rdfのgeneratorのスクリプトを変更したらしく、proteinのURIを使った記述が増えた。
尚、UniProtのエントリーに「.rdf」を足して出力されるRDF/XMLは以前のままで、generatorの設定を変えて出力しているらしい。
生物種ごとに振り分けるためのパーサが正しく動かなくなったので修正。

  • 2017_08版
<rdf:Description rdf:about="http://purl.uniprot.org/uniprot/K4N3B4">
  <rdf:type rdf:resource="http://purl.uniprot.org/core/Protein"/>
  (中略)
</rdf:Description>
(中略)
<rdf:Description rdf:about="http://purl.uniprot.org/uniprot/K4N3B4#attribution-54F404CEAF9AEC2DB3BD20D578C41D4F"> //protein idにattribution + hash値のフラグメントを付与したURI
  <evidence rdf:resource="http://purl.obolibrary.org/obo/ECO_0000313"/>
  <source rdf:resource="http://purl.uniprot.org/embl-cds/AFV31135.1"/>
</rdf:Description>
  • 2017_09版
<rdf:Description rdf:about="http://purl.uniprot.org/uniprot/K4N3B4">
  <rdf:type rdf:resource="http://purl.uniprot.org/core/Protein"/>
  (中略)
</rdf:Description>
(中略)
<rdf:Description rdf:about="http://purl.uniprot.org/uniprot/K4N3B4">  //proteinを主語にした記述が繰り返される
  <rdfs:seeAlso rdf:resource="http://purl.uniprot.org/embl-cds/AFV31135.1"/>
</rdf:Description>
rdf:IDエラー

2017年2月頃の更新においてUniProtのRDF/XMLでrdf:IDの記述エラーのSyntaxエラーが出てくるようになっていた。
UniProtに連絡していて一部修正されたが、まだエラーが残っていたので再度修正依頼中。

  • エラーになるRDF/XML (rdf:IDに":"が含まれるとエラー)
<rdf:type rdf:resource="http://purl.uniprot.org/core/Gene"/>
  <skos:prefLabel rdf:ID="_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">ifp-1:20</skos:prefLabel>
</rdf:Description>
<rdf:Description rdf:about="#_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">
  <attribution rdf:resource="http://purl.uniprot.org/uniprot/O66099#attribution-8AF4EAFC351D17441081F88A3FD0A02D"/>
</rdf:Description>
  • rapperエラー
rapper: Error - URI http://purl.uniprot.org/:293565 - Illegal rdf:ID value '_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20'
293564 <rdf:type rdf:resource="http://purl.uniprot.org/core/Gene"/>
293565 <skos:prefLabel rdf:ID="_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">ifp-1:20</skos:prefLabel>
293566 </rdf:Description>
  • エラーになるRDF/XML (rdf:IDに":"が含まれるとエラー)
<rdf:type rdf:resource="http://purl.uniprot.org/core/Gene"/>
  <skos:prefLabel rdf:ID="_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">ifp-1:20</skos:prefLabel>
</rdf:Description>
<rdf:Description rdf:about="#_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">
  <attribution rdf:resource="http://purl.uniprot.org/uniprot/O66099#attribution-8AF4EAFC351D17441081F88A3FD0A02D"/>
</rdf:Description>
  • rapperエラー
rapper: Error - URI http://purl.uniprot.org/:293565 - Illegal rdf:ID value '_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20'
293564 <rdf:type rdf:resource="http://purl.uniprot.org/core/Gene"/>
293565 <skos:prefLabel rdf:ID="_26D9B5787C9D4290_FFA56BCD0169E5A3_ifp-1:20">ifp-1:20</skos:prefLabel>
293566 </rdf:Description>
  • エラーになるRDF/XML (同一のrdf:IDが複数回出現するとエラー)
//1箇所目
<rdf:Description rdf:about="http://purl.uniprot.org/isoforms/P0DOE0-1">
  <name rdf:ID="_FB8BDA98F9648FFE_up.name_Glycoprotein_Q2">Glycoprotein Q2</name>
</rdf:Description>
<rdf:Description rdf:about="#_FB8BDA98F9648FFE_up.name_Glycoprotein_Q2">
  <attribution rdf:resource="http://purl.uniprot.org/uniprot/Q69572#attribution-E18EDCC207D9988364DADCCB54062DE4"/>
</rdf:Description>
//2箇所目
<rdf:Description rdf:about="http://purl.uniprot.org/isoforms/P0DOE0-1">
  <name rdf:ID="_FB8BDA98F9648FFE_up.name_Glycoprotein_Q2">Glycoprotein Q2</name>
</rdf:Description>
<rdf:Description rdf:about="#_FB8BDA98F9648FFE_up.name_Glycoprotein_Q2">
  <attribution rdf:resource="http://purl.uniprot.org/uniprot/P0DOE0#attribution-0EFAA078C1754FFD1247D6A9E3714ED9"/>
</rdf:Description>
  • rapperエラー
Writing /data/store/rdf/uniprot/current/uniprot_taxon.ttl/10000/10370.ttl ...
rapper: Parsing URI file:///data/store/rdf/uniprot/current/uniprot_taxon.rdf/10000/10370.rdf with parser rdfxml and base URI http://purl.uniprot.org/
rapper: Serializing with serializer turtle and base URI http://purl.uniprot.org/
rapper: Error - URI http://purl.uniprot.org/:9854 - Duplicated rdf:ID value '_FB8BDA98F9648FFE_up.name_Glycoprotein_Q2'

スクリプトの更新

UniProt

UniProtのRDF/XMLをtaxonomyごとに分割する"uniprot_taxon.rb"において、Proteinエントリーでsplitする判定がデータ更新によりうまくいかなくなったので修正。
rdf:about="{ProteinID}"が出現する度にエントリを区切っていたが、同じProteinでも複数回出現するようになったので、ProteinIDが別のIDに切り替わったか判定してエントリを分けるようにした。 7510a60

jBrowse (この対応は取り消し)

jBrowseのSPARQLが返って来ずタイムアウトエラーになるようになったため、SPARQLを見直した。
SeqからgeneやCDS等のfeatureを辿る"obo:so_part_of"predicateのインデックスが動作しなくなった。(ロード時にインデックスが壊れた or 使用件数が多い)
"obo:so_part_of"の指定でインデックスが働かないように変数で指定することで遅くはあるが返ってくるようになった d4eb157
ロード時にインデックスが壊れただけであれば次回更新時は元の正当なクエリで動作する可能性があるため、確認する。

インデックスが正常に生成されなかったことを疑い、全データをVirtuosoにロードし直した結果現象が解消された。

fasta生成の並列化

RefSeqのfasta生成&jBrowseデータ生成は、他のデータに依存しないので、並列実行するよう修正 d157c8a