I am trying to use:
to read an XML file produced with TMVA. The training used an spectator and when I call the constructor I see:
<FATAL> : Dataset[Default] : You declared 0 spectators in the Reader while there are 1
RReader class makes sense to me and it would be nice if it would be able to accept spectators or that this error be bypassed.
Just in case some else has this problem, I managed to remove the spectators from the XML file with:
for BDTXML in `find . -mindepth 2 -name "*.xml" -type f | sort`;do cat $BDTXML | grep -v "Spectator" > tmp.xml ORGNAME=$(echo $BDTXML | sed "s|.xml|_original.xml|g") #echo "mv $BDTXML $ORGNAME" mv $BDTXML $ORGNAME #echo "mv tmp.xml $BDTXML" mv tmp.xml $BDTXML diff -y -W 200 --suppress-common-lines $ORGNAME $BDTXML echo "" done
which should remove the lines with “Spectator” from the XML files in a given subdirectory (-mindepth 2) in the current directory.
I am using this version of ROOT: