Skip to content

conversion:num_invocation_logs

Timothy Lebo edited this page Feb 14, 2012 · 13 revisions
csv2rdf4lod-automation is licensed under the [Apache License, Version 2.0](https://github.com/timrdf/csv2rdf4lod-automation/wiki/License)

see Logging

When running the conversion trigger, the screen output is mirrored to a file in doc/logs/. If we count the number of logs in docs/logs/, we have a measure for how much effort people have spent enhancing the retrieved data. For example,

$ ls /srv/logd/data/source/data-rpi-edu/research-centers/version/2011-Oct-18/doc/logs/csv2rdf4lod_log_*.txt

doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_10_18.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_13_27.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_14_42.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_20_35.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_21_11.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_22_35.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_42_46.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_43_33.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_45_07.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_54_08.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_55_49.txt
doc/logs/csv2rdf4lod_log_e1_2011-10-18T17_56_49.txt
...

When publishing the data, the automation includes a triple in publish/data-rpi-edu-research-centers-2011-Oct-18.void.ttl:

<http://logd.tw.rpi.edu/source/data-rpi-edu/dataset/research-centers/version/2011-Oct-18> 
  <http://purl.org/twc/vocab/conversion/num_invocation_logs> 93 .
cr-trim-logs.sh -w

Queries

Number of times the converter has been invoked for each dataset (results):

PREFIX conversion: <http://purl.org/twc/vocab/conversion/>
SELECT DISTINCT(?versioned)
WHERE {
  GRAPH <http://logd.tw.rpi.edu/vocab/Dataset> {
    ?versioned conversion:num_invocation_logs ?count .
  }
} ORDER BY DESC(?count)

495 datasets that do not have the count (conversion needs to be re-run) (results):

PREFIX dcterms:    <http://purl.org/dc/terms/>
PREFIX conversion: <http://purl.org/twc/vocab/conversion/>

SELECT ?versioned MAX(?modified) as ?last_modified
WHERE {
  GRAPH <http://logd.tw.rpi.edu/vocab/Dataset> {
               ?versioned a conversion:VersionedDataset .
    OPTIONAL { ?versioned dcterms:modified            ?modified }
    OPTIONAL { ?versioned conversion:num_invocation_logs ?count }
  }
  FILTER(!bound(?count))
} ORDER BY ?last_modified ?versioned
Clone this wiki locally