mName = getNames (UTFile.replaceExtension(inputPath, nameExt));
}
catch (Exception e) {e.printStackTrace();}
PrintStream fout = UTOutput.createPrintBufferedFileStream(UTFile.replaceExtension(inputPath, outputExt));
CTReader reader = new CTReader(UTInput.createBufferedFileReader(inputPath));
CTTree cTree; DEPTree dTree; int n;
List<PBInstance> instances = null;
for (n=0; (cTree = reader.nextTree()) != null; n++)
{
if (language.equals(AbstractReader.LANG_EN))
CTLibEn.preprocessTree(cTree);
if (mProp != null)
{
instances = mProp.get(n);
addPBInstances(cTree, instances);
}
dTree = c2d.toDEPTree(cTree);
if (dTree == null)
{
// fout.println(getNullTree()+"\n");
}
else
{
if (morph != null) morph.process(dTree);
if (mSense != null) addWordSenses(cTree, dTree, mSense.get(n), DEPLibEn.FEAT_WS);
if (mVclass != null) addWordSenses(cTree, dTree, mVclass.get(n), DEPLibEn.FEAT_VN);
if (mName != null) addNames(cTree, dTree, mName.get(n));
if (mProp != null)
{
addRolesets(cTree, dTree, instances);
if (b_verbs_only) relabelLightVerb(dTree);
DEPLibEn.postLabel(dTree);
}
dTree = getDEPTreeWithoutEdited(cTree, dTree);
fout.println(dTree+"\n");
}
}
fout.close();
reader.close();
}
}