Skip to content
Snippets Groups Projects
Commit c728e343 authored by Franck Dary's avatar Franck Dary
Browse files

Fixed utf8 output

parent 295c38f8
No related branches found
No related tags found
No related merge requests found
#! /usr/bin/python3
import sys
import codecs
sys.stdout = codecs.getwriter('utf8')(sys.stdout)
sys.stderr = codecs.getwriter('utf8')(sys.stderr)
def printUsageAndExit() :
print("USAGE : %s file.conllu mcd"%sys.argv[0], file=sys.stderr)
......@@ -24,6 +21,9 @@ def readMCD(mcdFilename) :
return mcd
if __name__ == "__main__" :
sys.stdout = open(1, 'w', encoding='utf-8', closefd=False)
if len(sys.argv) != 3 :
printUsageAndExit()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment