Spaces:
Runtime error
Runtime error
File size: 562 Bytes
27979f6 9916d63 58b7eaf 27979f6 c60e715 58b7eaf c5729e2 58b7eaf 27979f6 9916d63 c5729e2 9916d63 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
import os
from datasets import load_dataset, Dataset
TOKEN = os.environ.get("DEBUG")
requests_dataset = load_dataset("AIEnergyScore/requests_debug", split="test")
def normalize_task(task):
# Makes assumption about how the task names are being written, and called.
return '_'.join(task.split()).lower()
requests_dset = requests_dataset.to_pandas()
for model, task in requests_dset[['model', 'task']].loc[
requests_dset['status'] == 'PENDING'].to_dict(orient='split', index=False)[
'data']:
print("%s,%s" % (model, normalize_task(task)))
|