Untitled conversation
- User
- Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.
ns's a' t'r 'in __init.py' and tell GAE that all your application code and unit tests
are going to be in the same directory with run.py.
To listen to on port 7999: python restfulserver.py --port 7999 """
@app.route("/") async def index(): return await get_static_file('index.html')
@app.route('/assets/js/app.js') async def static_js(): return app.send_static_file('app.js')
@app.route('/provider', methods=['POST']) async def go(): # Let's start by just printing out the received JSON data. req_data = request.get_json(force=True) app.logger.info("%s" % req_data)
if text.isdigit():
output = "Le lien youtube contenant les résultats est : https://xkcd.com/{0}".format(subreddit)
else:
output = "This subreddit doesn't exist! Please register with a different one."
return render_template("index.html", t = output, subreddits = constants.subreddits)
@app.route('/form') def addword(): return render_template("form.html", subreddits = constants.subreddits)
@app.route('/results', methods=["GET", "POST"])
def home():
categories = ['danceability',
'energy',
'loudness',
'speechiness',
'acousticness',
'instrumentalness',
'liveness',
'valence',
'tempo']
columns = ['Word']
for song in song_dict:
columns.append(song)
with open('dandy_reviewData.tsv', 'w') as file:
writer = csv.writer(file, delimiter='\t')
writer.writerow(columns)
for song in song_dict:
for emo, frqs in sorted(song.items()):
line = [emo]
for col in columns[1:]:
line.append(frqs[col])
#print(line)
data.append(line)
return data
def extract_column(data, col): """ Extracts a particular column from a .csv file.
Returns:
dataframe
Keyword arguments:
data -- csv file data to be evaluated
col -- column id
"""
s = pd.read_csv(data)
return s
def get_playlists(input_directory): imported_playlists = [] client = SpotifyClient(SpotifyObject()) folders = os.listdir(input_directory) # list containing all of MyFile objects for folder in folders: for path, subdirs, files in os.walk(input_directory+"/"+folder): for file in files: if '.json' in file: with open(f"{input_directory}/{folder}/{file}") as f: data = json.load(f) for i, x in enumerate(data): if not pd.isnull(x[1]["track_id"]): song_id = x[1]['track_id'] while self.mutex: sleep(1) THREADS.append(t.Thread(target=nput, args=(sql_query,song_id,spotify_id,opq_song_names,opq_data,music_info_url))) if (os.getenv("N_THREADS") is not None) and ( int(os.environ.get("N_THREADS")) > 1 or multiprocessing.cpu_count() > 1): threadPool.useThreadPool(2) executed = 1
ts = ThreadPool() with open(sys.argv[1], 'r', newline='') as file: # discard header file.readline() for line in file: fid, fpid, pkl_file, mpl_file, csv_file, token_root, ggp_results = line.strip().split('\t') p = multiprocessing.Process(target=run_tile, args=(fid, fpid, pkl_file, mpl_file, event_lat_lng, rel_coords)) procs.append(p) p.start() if len(proc_list) % 16 == 0: ensure_threads_alive()
ensure_threads_alive() print('Finished')
drottycat 2020-12-16: I think you could do something like this: leveraging the `dask` engine. I can generate data sampled with a lower sampling rate than the original dataset being modelled, we can perform the full model fitting and evaluate it's performance.
import xray, matplotlib.pyplot as plt
import numpy as np from sklearn.datasets import fetch_openml
X, y = fetch_openml('breastcancer', version=1, return_X_y=True, as_frame=True) start = timeit.default_timer()
x_train, x_test, y_train, y_test = train_test_split(X, y