tech_poet_society / utils /preprocessing.py
ddiddu's picture
Upload 16 files
5c7be38
raw
history blame
304 Bytes
import csv
def preprocess_play(filepath):
out_str = []
unique_names = set()
with open(filepath) as f:
reader = csv.reader(f, delimiter=',')
for row in reader:
unique_names.add(row[0])
out_str.append([row[0], row[1]])
return (out_str, unique_names)