with xlrd.open_workbook('a_file.xls') as wb:
    sh = wb.sheet_by_index(0)
with open('a_file.csv', 'wb') as f:
    c = csv.writer(f)
for r in range(sh.nrows):
    c.writerow(sh.row_values(r))
How to save an Excel worksheet as CSV from Python (Unix)?