Tweaks to script to run and output rdf