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
# Sebastian Raschka 09/24/2022 | |
# Fixed to avoid problems with spaces and other special characters in filenames, Ken Arnold 10/25/2022 | |
# | |
# Create a new conda environment and packages | |
# conda create -n whisper python=3.9 | |
# conda activate whisper | |
# conda install mlxtend -c conda-forge | |
# Install ffmpeg | |
# macOS & homebrew |
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 pandas as pd | |
import sys | |
filename, outfile = sys.argv[1:3] | |
responses = pd.read_csv(filename) | |
def format_row(row): | |
return '\n'.join(["<p><b>{}</b><br>{}</p>".format(k, v.replace('\n', '<br>')) for k, v in row.iteritems()]) | |
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
#!/usr/bin/env python | |
import numpy as np | |
import sys | |
from six import iteritems | |
from six.moves import zip as izip | |
from six.moves import xrange | |
from itertools import chain, repeat, islice |
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 sys | |
tr = [ | |
(u'\u2018', "`"), | |
(u'\u2019',"'"), | |
(u'\u201c', "``"), | |
(u'\u201d', "''") | |
] | |
s = sys.stdin.read().decode('utf8') | |
for a, b in tr: | |
s = s.replace(a, b) |