Created
April 30, 2013 16:24
-
-
Save samarthbhaskar/5489848 to your computer and use it in GitHub Desktop.
unicode sucks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import csv | |
reader = csv.reader(open("/Users/sbhaskar/Dropbox/All_out/french_results/CSV/Sheet_1.csv","rU")) | |
for r in reader: | |
print r | |
import unicodedata | |
source = r | |
output=[] | |
for s in r: | |
t=unicodedata.normalize('NFKD', unicode(s)).encode('ascii', 'ignore') | |
output.append(t) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment