fout.close();
}
void convertKaist(String[] args)
{
AbstractC2DConverter converter = new KaistC2DConverter(new HeadRuleMap(UTInput.createBufferedFileReader(args[0])));
String[] inputFiles = UTFile.getSortedFileList(args[1], "ptb");
String outputFile;
PrintStream fout;
CTReader reader;
DEPTree dTree;
CTTree cTree;
for (String inputFile : inputFiles)
{
outputFile = UTFile.replaceExtension(inputFile, "dep");
reader = new CTReader(UTInput.createBufferedFileReader(inputFile));
fout = UTOutput.createPrintBufferedFileStream(outputFile);
System.out.println(outputFile);
while ((cTree = reader.nextTree()) != null)
{
dTree = converter.toDEPTree(cTree);
fout.println(dTree.toStringDEP()+"\n");
}
reader.close();
fout.close();