Skip to content

Commit 9c79ee2

Browse files
moves sample data to S3 bucket
1 parent 1523be6 commit 9c79ee2

File tree

3 files changed

+21
-74
lines changed

3 files changed

+21
-74
lines changed

python-recipes/finetuning/00_text_finetuning.ipynb

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,27 @@
7474
"test_data = 'sample_testset.csv'"
7575
]
7676
},
77+
{
78+
"cell_type": "code",
79+
"execution_count": 49,
80+
"metadata": {},
81+
"outputs": [],
82+
"source": [
83+
"import requests\n",
84+
"import os\n",
85+
"\n",
86+
"if not (os.path.exists(f\"./datasets/{train_data}\") and os.path.exists(f\"./datasets/{test_data}\")):\n",
87+
" if not os.path.exists('./datasets/'):\n",
88+
" os.mkdir('./datasets/')\n",
89+
"\n",
90+
" # download the files and save them locally\n",
91+
" for file in [train_data, test_data]:\n",
92+
" url = f'https://redis-ai-resources.s3.us-east-2.amazonaws.com/finetuning/datasets/{file}'\n",
93+
" r = requests.get(url)\n",
94+
" with open(f'./datasets/{file}', 'wb') as f:\n",
95+
" f.write(r.content)"
96+
]
97+
},
7798
{
7899
"cell_type": "code",
79100
"execution_count": 32,

python-recipes/finetuning/datasets/sample_dataset.csv

Lines changed: 0 additions & 53 deletions
This file was deleted.

python-recipes/finetuning/datasets/sample_testset.csv

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)