update
Browse files- .ipynb_checkpoints/AVA-checkpoint.py +1 -1
- AVA.py +1 -1
- notebooks/Test.ipynb +7 -100
.ipynb_checkpoints/AVA-checkpoint.py
CHANGED
|
@@ -57,7 +57,7 @@ class AVA(datasets.GeneratorBasedBuilder):
|
|
| 57 |
if path.endswith(".jpg"):
|
| 58 |
# image filepath format: <IMAGE_FILE NAME>_<SYNSET_ID>.JPEG
|
| 59 |
_id = int(os.path.splitext(path)[0].split('/')[-1])
|
| 60 |
-
_metadata = self.
|
| 61 |
ex = {"image": {"path": path, "bytes": file.read()},
|
| 62 |
"rating_counts": _metadata[0],
|
| 63 |
"text_tag0":_metadata[1],
|
|
|
|
| 57 |
if path.endswith(".jpg"):
|
| 58 |
# image filepath format: <IMAGE_FILE NAME>_<SYNSET_ID>.JPEG
|
| 59 |
_id = int(os.path.splitext(path)[0].split('/')[-1])
|
| 60 |
+
_metadata = self.dict_metadata[_id]
|
| 61 |
ex = {"image": {"path": path, "bytes": file.read()},
|
| 62 |
"rating_counts": _metadata[0],
|
| 63 |
"text_tag0":_metadata[1],
|
AVA.py
CHANGED
|
@@ -57,7 +57,7 @@ class AVA(datasets.GeneratorBasedBuilder):
|
|
| 57 |
if path.endswith(".jpg"):
|
| 58 |
# image filepath format: <IMAGE_FILE NAME>_<SYNSET_ID>.JPEG
|
| 59 |
_id = int(os.path.splitext(path)[0].split('/')[-1])
|
| 60 |
-
_metadata = self.
|
| 61 |
ex = {"image": {"path": path, "bytes": file.read()},
|
| 62 |
"rating_counts": _metadata[0],
|
| 63 |
"text_tag0":_metadata[1],
|
|
|
|
| 57 |
if path.endswith(".jpg"):
|
| 58 |
# image filepath format: <IMAGE_FILE NAME>_<SYNSET_ID>.JPEG
|
| 59 |
_id = int(os.path.splitext(path)[0].split('/')[-1])
|
| 60 |
+
_metadata = self.dict_metadata[_id]
|
| 61 |
ex = {"image": {"path": path, "bytes": file.read()},
|
| 62 |
"rating_counts": _metadata[0],
|
| 63 |
"text_tag0":_metadata[1],
|
notebooks/Test.ipynb
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
"cells": [
|
| 3 |
{
|
| 4 |
"cell_type": "code",
|
| 5 |
-
"execution_count":
|
| 6 |
"id": "aef315bf",
|
| 7 |
"metadata": {},
|
| 8 |
"outputs": [],
|
|
@@ -12,19 +12,19 @@
|
|
| 12 |
},
|
| 13 |
{
|
| 14 |
"cell_type": "code",
|
| 15 |
-
"execution_count":
|
| 16 |
"id": "c0ed6498",
|
| 17 |
"metadata": {},
|
| 18 |
"outputs": [
|
| 19 |
{
|
| 20 |
"data": {
|
| 21 |
"application/vnd.jupyter.widget-view+json": {
|
| 22 |
-
"model_id": "
|
| 23 |
"version_major": 2,
|
| 24 |
"version_minor": 0
|
| 25 |
},
|
| 26 |
"text/plain": [
|
| 27 |
-
"Downloading builder script: 0%| | 0.00/2.
|
| 28 |
]
|
| 29 |
},
|
| 30 |
"metadata": {},
|
|
@@ -34,13 +34,13 @@
|
|
| 34 |
"name": "stdout",
|
| 35 |
"output_type": "stream",
|
| 36 |
"text": [
|
| 37 |
-
"Downloading and preparing dataset ava/default to /home/william/.cache/huggingface/datasets/will33am___ava/default/1.0.0/
|
| 38 |
]
|
| 39 |
},
|
| 40 |
{
|
| 41 |
"data": {
|
| 42 |
"application/vnd.jupyter.widget-view+json": {
|
| 43 |
-
"model_id": "
|
| 44 |
"version_major": 2,
|
| 45 |
"version_minor": 0
|
| 46 |
},
|
|
@@ -50,99 +50,6 @@
|
|
| 50 |
},
|
| 51 |
"metadata": {},
|
| 52 |
"output_type": "display_data"
|
| 53 |
-
},
|
| 54 |
-
{
|
| 55 |
-
"name": "stderr",
|
| 56 |
-
"output_type": "stream",
|
| 57 |
-
"text": [
|
| 58 |
-
"Computing checksums of downloaded files. They can be used for integrity verification. You can disable this by passing ignore_verifications=True to load_dataset\n"
|
| 59 |
-
]
|
| 60 |
-
},
|
| 61 |
-
{
|
| 62 |
-
"data": {
|
| 63 |
-
"application/vnd.jupyter.widget-view+json": {
|
| 64 |
-
"model_id": "523195fe98504ce98071f9fd39a2b9ca",
|
| 65 |
-
"version_major": 2,
|
| 66 |
-
"version_minor": 0
|
| 67 |
-
},
|
| 68 |
-
"text/plain": [
|
| 69 |
-
"Computing checksums: 100%|##########| 1/1 [01:33<00:00, 93.72s/it]"
|
| 70 |
-
]
|
| 71 |
-
},
|
| 72 |
-
"metadata": {},
|
| 73 |
-
"output_type": "display_data"
|
| 74 |
-
},
|
| 75 |
-
{
|
| 76 |
-
"name": "stdout",
|
| 77 |
-
"output_type": "stream",
|
| 78 |
-
"text": [
|
| 79 |
-
"Init loading Metadata\n"
|
| 80 |
-
]
|
| 81 |
-
},
|
| 82 |
-
{
|
| 83 |
-
"data": {
|
| 84 |
-
"application/vnd.jupyter.widget-view+json": {
|
| 85 |
-
"model_id": "a7159023978844d0b3059697f046b975",
|
| 86 |
-
"version_major": 2,
|
| 87 |
-
"version_minor": 0
|
| 88 |
-
},
|
| 89 |
-
"text/plain": [
|
| 90 |
-
"Downloading data: 0%| | 0.00/42.4M [00:00<?, ?B/s]"
|
| 91 |
-
]
|
| 92 |
-
},
|
| 93 |
-
"metadata": {},
|
| 94 |
-
"output_type": "display_data"
|
| 95 |
-
},
|
| 96 |
-
{
|
| 97 |
-
"name": "stdout",
|
| 98 |
-
"output_type": "stream",
|
| 99 |
-
"text": [
|
| 100 |
-
"Finish loading Metadata\n"
|
| 101 |
-
]
|
| 102 |
-
},
|
| 103 |
-
{
|
| 104 |
-
"data": {
|
| 105 |
-
"application/vnd.jupyter.widget-view+json": {
|
| 106 |
-
"model_id": "21ade8bfc87040989558d0778b21aeed",
|
| 107 |
-
"version_major": 2,
|
| 108 |
-
"version_minor": 0
|
| 109 |
-
},
|
| 110 |
-
"text/plain": [
|
| 111 |
-
"Generating train split: 0 examples [00:00, ? examples/s]"
|
| 112 |
-
]
|
| 113 |
-
},
|
| 114 |
-
"metadata": {},
|
| 115 |
-
"output_type": "display_data"
|
| 116 |
-
},
|
| 117 |
-
{
|
| 118 |
-
"name": "stderr",
|
| 119 |
-
"output_type": "stream",
|
| 120 |
-
"text": [
|
| 121 |
-
"\n",
|
| 122 |
-
"0it [00:00, ?it/s]\u001b[A\n"
|
| 123 |
-
]
|
| 124 |
-
},
|
| 125 |
-
{
|
| 126 |
-
"ename": "DatasetGenerationError",
|
| 127 |
-
"evalue": "An error occurred while generating the dataset",
|
| 128 |
-
"output_type": "error",
|
| 129 |
-
"traceback": [
|
| 130 |
-
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
|
| 131 |
-
"\u001b[0;31mNameError\u001b[0m Traceback (most recent call last)",
|
| 132 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:1570\u001b[0m, in \u001b[0;36mGeneratorBasedBuilder._prepare_split_single\u001b[0;34m(self, gen_kwargs, fpath, file_format, max_shard_size, split_info, check_duplicate_keys, job_id)\u001b[0m\n\u001b[1;32m 1569\u001b[0m _time \u001b[38;5;241m=\u001b[39m time\u001b[38;5;241m.\u001b[39mtime()\n\u001b[0;32m-> 1570\u001b[0m \u001b[38;5;28;01mfor\u001b[39;00m key, record \u001b[38;5;129;01min\u001b[39;00m generator:\n\u001b[1;32m 1571\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m max_shard_size \u001b[38;5;129;01mis\u001b[39;00m \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;28;01mNone\u001b[39;00m \u001b[38;5;129;01mand\u001b[39;00m writer\u001b[38;5;241m.\u001b[39m_num_bytes \u001b[38;5;241m>\u001b[39m max_shard_size:\n",
|
| 133 |
-
"File \u001b[0;32m~/.cache/huggingface/modules/datasets_modules/datasets/will33am--AVA/ce866a196bfdfabe8895e8b963c38dcc8fe5e85e20c47b83ea842e3459fe032a/AVA.py:62\u001b[0m, in \u001b[0;36mAVA._generate_examples\u001b[0;34m(self, archives, split)\u001b[0m\n\u001b[1;32m 60\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m path\u001b[38;5;241m.\u001b[39mendswith(\u001b[38;5;124m\"\u001b[39m\u001b[38;5;124m.jpg\u001b[39m\u001b[38;5;124m\"\u001b[39m):\n\u001b[1;32m 61\u001b[0m \u001b[38;5;66;03m# image filepath format: <IMAGE_FILE NAME>_<SYNSET_ID>.JPEG\u001b[39;00m\n\u001b[0;32m---> 62\u001b[0m _id \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mint\u001b[39m(os\u001b[38;5;241m.\u001b[39mpath\u001b[38;5;241m.\u001b[39msplitext(\u001b[43mb\u001b[49m[\u001b[38;5;241m0\u001b[39m])[\u001b[38;5;241m0\u001b[39m]\u001b[38;5;241m.\u001b[39msplit(\u001b[38;5;124m'\u001b[39m\u001b[38;5;124m/\u001b[39m\u001b[38;5;124m'\u001b[39m)[\u001b[38;5;241m-\u001b[39m\u001b[38;5;241m1\u001b[39m])\n\u001b[1;32m 63\u001b[0m _metadata \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mDICT_METADATA[_id]\n",
|
| 134 |
-
"\u001b[0;31mNameError\u001b[0m: name 'b' is not defined",
|
| 135 |
-
"\nThe above exception was the direct cause of the following exception:\n",
|
| 136 |
-
"\u001b[0;31mDatasetGenerationError\u001b[0m Traceback (most recent call last)",
|
| 137 |
-
"File \u001b[0;32m<timed exec>:1\u001b[0m\n",
|
| 138 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/load.py:1757\u001b[0m, in \u001b[0;36mload_dataset\u001b[0;34m(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, num_proc, **config_kwargs)\u001b[0m\n\u001b[1;32m 1754\u001b[0m try_from_hf_gcs \u001b[38;5;241m=\u001b[39m path \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;129;01min\u001b[39;00m _PACKAGED_DATASETS_MODULES\n\u001b[1;32m 1756\u001b[0m \u001b[38;5;66;03m# Download and prepare data\u001b[39;00m\n\u001b[0;32m-> 1757\u001b[0m \u001b[43mbuilder_instance\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mdownload_and_prepare\u001b[49m\u001b[43m(\u001b[49m\n\u001b[1;32m 1758\u001b[0m \u001b[43m \u001b[49m\u001b[43mdownload_config\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mdownload_config\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 1759\u001b[0m \u001b[43m \u001b[49m\u001b[43mdownload_mode\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mdownload_mode\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 1760\u001b[0m \u001b[43m \u001b[49m\u001b[43mignore_verifications\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mignore_verifications\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 1761\u001b[0m \u001b[43m \u001b[49m\u001b[43mtry_from_hf_gcs\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mtry_from_hf_gcs\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 1762\u001b[0m \u001b[43m \u001b[49m\u001b[43mnum_proc\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mnum_proc\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 1763\u001b[0m \u001b[43m\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 1765\u001b[0m \u001b[38;5;66;03m# Build dataset for splits\u001b[39;00m\n\u001b[1;32m 1766\u001b[0m keep_in_memory \u001b[38;5;241m=\u001b[39m (\n\u001b[1;32m 1767\u001b[0m keep_in_memory \u001b[38;5;28;01mif\u001b[39;00m keep_in_memory \u001b[38;5;129;01mis\u001b[39;00m \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;28;01mNone\u001b[39;00m \u001b[38;5;28;01melse\u001b[39;00m is_small_dataset(builder_instance\u001b[38;5;241m.\u001b[39minfo\u001b[38;5;241m.\u001b[39mdataset_size)\n\u001b[1;32m 1768\u001b[0m )\n",
|
| 139 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:860\u001b[0m, in \u001b[0;36mDatasetBuilder.download_and_prepare\u001b[0;34m(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, num_proc, storage_options, **download_and_prepare_kwargs)\u001b[0m\n\u001b[1;32m 858\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m num_proc \u001b[38;5;129;01mis\u001b[39;00m \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;28;01mNone\u001b[39;00m:\n\u001b[1;32m 859\u001b[0m prepare_split_kwargs[\u001b[38;5;124m\"\u001b[39m\u001b[38;5;124mnum_proc\u001b[39m\u001b[38;5;124m\"\u001b[39m] \u001b[38;5;241m=\u001b[39m num_proc\n\u001b[0;32m--> 860\u001b[0m \u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43m_download_and_prepare\u001b[49m\u001b[43m(\u001b[49m\n\u001b[1;32m 861\u001b[0m \u001b[43m \u001b[49m\u001b[43mdl_manager\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mdl_manager\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 862\u001b[0m \u001b[43m \u001b[49m\u001b[43mverify_infos\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mverify_infos\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 863\u001b[0m \u001b[43m \u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43mprepare_split_kwargs\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 864\u001b[0m \u001b[43m \u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43mdownload_and_prepare_kwargs\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 865\u001b[0m \u001b[43m \u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 866\u001b[0m \u001b[38;5;66;03m# Sync info\u001b[39;00m\n\u001b[1;32m 867\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39minfo\u001b[38;5;241m.\u001b[39mdataset_size \u001b[38;5;241m=\u001b[39m \u001b[38;5;28msum\u001b[39m(split\u001b[38;5;241m.\u001b[39mnum_bytes \u001b[38;5;28;01mfor\u001b[39;00m split \u001b[38;5;129;01min\u001b[39;00m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39minfo\u001b[38;5;241m.\u001b[39msplits\u001b[38;5;241m.\u001b[39mvalues())\n",
|
| 140 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:1611\u001b[0m, in \u001b[0;36mGeneratorBasedBuilder._download_and_prepare\u001b[0;34m(self, dl_manager, verify_infos, **prepare_splits_kwargs)\u001b[0m\n\u001b[1;32m 1610\u001b[0m \u001b[38;5;28;01mdef\u001b[39;00m \u001b[38;5;21m_download_and_prepare\u001b[39m(\u001b[38;5;28mself\u001b[39m, dl_manager, verify_infos, \u001b[38;5;241m*\u001b[39m\u001b[38;5;241m*\u001b[39mprepare_splits_kwargs):\n\u001b[0;32m-> 1611\u001b[0m \u001b[38;5;28;43msuper\u001b[39;49m\u001b[43m(\u001b[49m\u001b[43m)\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43m_download_and_prepare\u001b[49m\u001b[43m(\u001b[49m\n\u001b[1;32m 1612\u001b[0m \u001b[43m \u001b[49m\u001b[43mdl_manager\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mverify_infos\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mcheck_duplicate_keys\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mverify_infos\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43mprepare_splits_kwargs\u001b[49m\n\u001b[1;32m 1613\u001b[0m \u001b[43m \u001b[49m\u001b[43m)\u001b[49m\n",
|
| 141 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:953\u001b[0m, in \u001b[0;36mDatasetBuilder._download_and_prepare\u001b[0;34m(self, dl_manager, verify_infos, **prepare_split_kwargs)\u001b[0m\n\u001b[1;32m 949\u001b[0m split_dict\u001b[38;5;241m.\u001b[39madd(split_generator\u001b[38;5;241m.\u001b[39msplit_info)\n\u001b[1;32m 951\u001b[0m \u001b[38;5;28;01mtry\u001b[39;00m:\n\u001b[1;32m 952\u001b[0m \u001b[38;5;66;03m# Prepare split will record examples associated to the split\u001b[39;00m\n\u001b[0;32m--> 953\u001b[0m \u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43m_prepare_split\u001b[49m\u001b[43m(\u001b[49m\u001b[43msplit_generator\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43mprepare_split_kwargs\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 954\u001b[0m \u001b[38;5;28;01mexcept\u001b[39;00m \u001b[38;5;167;01mOSError\u001b[39;00m \u001b[38;5;28;01mas\u001b[39;00m e:\n\u001b[1;32m 955\u001b[0m \u001b[38;5;28;01mraise\u001b[39;00m \u001b[38;5;167;01mOSError\u001b[39;00m(\n\u001b[1;32m 956\u001b[0m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;124mCannot find data file. \u001b[39m\u001b[38;5;124m\"\u001b[39m\n\u001b[1;32m 957\u001b[0m \u001b[38;5;241m+\u001b[39m (\u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mmanual_download_instructions \u001b[38;5;129;01mor\u001b[39;00m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;124m\"\u001b[39m)\n\u001b[1;32m 958\u001b[0m \u001b[38;5;241m+\u001b[39m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;130;01m\\n\u001b[39;00m\u001b[38;5;124mOriginal error:\u001b[39m\u001b[38;5;130;01m\\n\u001b[39;00m\u001b[38;5;124m\"\u001b[39m\n\u001b[1;32m 959\u001b[0m \u001b[38;5;241m+\u001b[39m \u001b[38;5;28mstr\u001b[39m(e)\n\u001b[1;32m 960\u001b[0m ) \u001b[38;5;28;01mfrom\u001b[39;00m \u001b[38;5;28mNone\u001b[39m\n",
|
| 142 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:1449\u001b[0m, in \u001b[0;36mGeneratorBasedBuilder._prepare_split\u001b[0;34m(self, split_generator, check_duplicate_keys, file_format, num_proc, max_shard_size)\u001b[0m\n\u001b[1;32m 1447\u001b[0m gen_kwargs \u001b[38;5;241m=\u001b[39m split_generator\u001b[38;5;241m.\u001b[39mgen_kwargs\n\u001b[1;32m 1448\u001b[0m job_id \u001b[38;5;241m=\u001b[39m \u001b[38;5;241m0\u001b[39m\n\u001b[0;32m-> 1449\u001b[0m \u001b[38;5;28;01mfor\u001b[39;00m job_id, done, content \u001b[38;5;129;01min\u001b[39;00m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39m_prepare_split_single(\n\u001b[1;32m 1450\u001b[0m gen_kwargs\u001b[38;5;241m=\u001b[39mgen_kwargs, job_id\u001b[38;5;241m=\u001b[39mjob_id, \u001b[38;5;241m*\u001b[39m\u001b[38;5;241m*\u001b[39m_prepare_split_args\n\u001b[1;32m 1451\u001b[0m ):\n\u001b[1;32m 1452\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m done:\n\u001b[1;32m 1453\u001b[0m result \u001b[38;5;241m=\u001b[39m content\n",
|
| 143 |
-
"File \u001b[0;32m/opt/conda/envs/hugginface/lib/python3.8/site-packages/datasets/builder.py:1606\u001b[0m, in \u001b[0;36mGeneratorBasedBuilder._prepare_split_single\u001b[0;34m(self, gen_kwargs, fpath, file_format, max_shard_size, split_info, check_duplicate_keys, job_id)\u001b[0m\n\u001b[1;32m 1604\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m \u001b[38;5;28misinstance\u001b[39m(e, SchemaInferenceError) \u001b[38;5;129;01mand\u001b[39;00m e\u001b[38;5;241m.\u001b[39m__context__ \u001b[38;5;129;01mis\u001b[39;00m \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;28;01mNone\u001b[39;00m:\n\u001b[1;32m 1605\u001b[0m e \u001b[38;5;241m=\u001b[39m e\u001b[38;5;241m.\u001b[39m__context__\n\u001b[0;32m-> 1606\u001b[0m \u001b[38;5;28;01mraise\u001b[39;00m DatasetGenerationError(\u001b[38;5;124m\"\u001b[39m\u001b[38;5;124mAn error occurred while generating the dataset\u001b[39m\u001b[38;5;124m\"\u001b[39m) \u001b[38;5;28;01mfrom\u001b[39;00m \u001b[38;5;21;01me\u001b[39;00m\n\u001b[1;32m 1608\u001b[0m \u001b[38;5;28;01myield\u001b[39;00m job_id, \u001b[38;5;28;01mTrue\u001b[39;00m, (total_num_examples, total_num_bytes, writer\u001b[38;5;241m.\u001b[39m_features, num_shards, shard_lengths)\n",
|
| 144 |
-
"\u001b[0;31mDatasetGenerationError\u001b[0m: An error occurred while generating the dataset"
|
| 145 |
-
]
|
| 146 |
}
|
| 147 |
],
|
| 148 |
"source": [
|
|
@@ -153,7 +60,7 @@
|
|
| 153 |
{
|
| 154 |
"cell_type": "code",
|
| 155 |
"execution_count": null,
|
| 156 |
-
"id": "
|
| 157 |
"metadata": {},
|
| 158 |
"outputs": [],
|
| 159 |
"source": []
|
|
|
|
| 2 |
"cells": [
|
| 3 |
{
|
| 4 |
"cell_type": "code",
|
| 5 |
+
"execution_count": 3,
|
| 6 |
"id": "aef315bf",
|
| 7 |
"metadata": {},
|
| 8 |
"outputs": [],
|
|
|
|
| 12 |
},
|
| 13 |
{
|
| 14 |
"cell_type": "code",
|
| 15 |
+
"execution_count": null,
|
| 16 |
"id": "c0ed6498",
|
| 17 |
"metadata": {},
|
| 18 |
"outputs": [
|
| 19 |
{
|
| 20 |
"data": {
|
| 21 |
"application/vnd.jupyter.widget-view+json": {
|
| 22 |
+
"model_id": "f4ed52d19cfd40329ebbc4d9e6b9b8ff",
|
| 23 |
"version_major": 2,
|
| 24 |
"version_minor": 0
|
| 25 |
},
|
| 26 |
"text/plain": [
|
| 27 |
+
"Downloading builder script: 0%| | 0.00/2.16k [00:00<?, ?B/s]"
|
| 28 |
]
|
| 29 |
},
|
| 30 |
"metadata": {},
|
|
|
|
| 34 |
"name": "stdout",
|
| 35 |
"output_type": "stream",
|
| 36 |
"text": [
|
| 37 |
+
"Downloading and preparing dataset ava/default to /home/william/.cache/huggingface/datasets/will33am___ava/default/1.0.0/b25331909ca9a0584688517c5b03689144393394f220cb4466e16bca4f72400e...\n"
|
| 38 |
]
|
| 39 |
},
|
| 40 |
{
|
| 41 |
"data": {
|
| 42 |
"application/vnd.jupyter.widget-view+json": {
|
| 43 |
+
"model_id": "d233ac0e5616412aae8ebec9fa9dc7be",
|
| 44 |
"version_major": 2,
|
| 45 |
"version_minor": 0
|
| 46 |
},
|
|
|
|
| 50 |
},
|
| 51 |
"metadata": {},
|
| 52 |
"output_type": "display_data"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 53 |
}
|
| 54 |
],
|
| 55 |
"source": [
|
|
|
|
| 60 |
{
|
| 61 |
"cell_type": "code",
|
| 62 |
"execution_count": null,
|
| 63 |
+
"id": "64d98db9",
|
| 64 |
"metadata": {},
|
| 65 |
"outputs": [],
|
| 66 |
"source": []
|