Skip to content

Instantly share code, notes, and snippets.

@vinitkumar
Created September 30, 2018 07:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vinitkumar/96a947d36cb67a77d9503f621c07998e to your computer and use it in GitHub Desktop.
Save vinitkumar/96a947d36cb67a77d9503f621c07998e to your computer and use it in GitHub Desktop.
from itertools import repeat
import csv
with open('sheet13.tsv', 'rb') as tsvin, open('new.csv', 'wb') as csvout:
tsvin = csv.reader(tsvin, delimiter='\t')
csvout = csv.writer(csvout)
img_list = []
for row in tsvin:
img_list.append({row[0]:row[1].split('.')[0]},)
print(img_list)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment