Yassine
commited on
Commit
·
335c4d1
1
Parent(s):
90de87b
some renaming
Browse files- commavq.py +5 -5
commavq.py
CHANGED
|
@@ -9,7 +9,7 @@ _URLS = {
|
|
| 9 |
'train': [
|
| 10 |
f'https://huggingface.co/datasets/commaai/commavq/resolve/main/data_{i*SHARD_SIZE}_to_{(i+1)*SHARD_SIZE}.zip' for i in range(NUM_SHARDS)
|
| 11 |
],
|
| 12 |
-
'val':
|
| 13 |
}
|
| 14 |
|
| 15 |
_DESCRIPTION = """\
|
|
@@ -33,13 +33,13 @@ class CommaVQ(datasets.GeneratorBasedBuilder):
|
|
| 33 |
local_extracted_archive = dl_manager.extract(downloaded_files) if not dl_manager.is_streaming else None
|
| 34 |
return [
|
| 35 |
datasets.SplitGenerator(
|
| 36 |
-
name=
|
| 37 |
gen_kwargs={"local_extracted_archive":local_extracted_archive['train'][i], "files": dl_manager.iter_archive(downloaded_files['train'][i])}
|
| 38 |
) for i in range(len(downloaded_files['train']))] + [
|
| 39 |
datasets.SplitGenerator(
|
| 40 |
-
name=
|
| 41 |
-
gen_kwargs={"local_extracted_archive":local_extracted_archive['val']
|
| 42 |
-
)
|
| 43 |
]
|
| 44 |
|
| 45 |
def _generate_examples(self, local_extracted_archive, files):
|
|
|
|
| 9 |
'train': [
|
| 10 |
f'https://huggingface.co/datasets/commaai/commavq/resolve/main/data_{i*SHARD_SIZE}_to_{(i+1)*SHARD_SIZE}.zip' for i in range(NUM_SHARDS)
|
| 11 |
],
|
| 12 |
+
'val': f'https://huggingface.co/datasets/commaai/commavq/resolve/main/val.zip'
|
| 13 |
}
|
| 14 |
|
| 15 |
_DESCRIPTION = """\
|
|
|
|
| 33 |
local_extracted_archive = dl_manager.extract(downloaded_files) if not dl_manager.is_streaming else None
|
| 34 |
return [
|
| 35 |
datasets.SplitGenerator(
|
| 36 |
+
name=f'train_{i}',
|
| 37 |
gen_kwargs={"local_extracted_archive":local_extracted_archive['train'][i], "files": dl_manager.iter_archive(downloaded_files['train'][i])}
|
| 38 |
) for i in range(len(downloaded_files['train']))] + [
|
| 39 |
datasets.SplitGenerator(
|
| 40 |
+
name='val',
|
| 41 |
+
gen_kwargs={"local_extracted_archive":local_extracted_archive['val'], "files": dl_manager.iter_archive(downloaded_files['val'])}
|
| 42 |
+
)
|
| 43 |
]
|
| 44 |
|
| 45 |
def _generate_examples(self, local_extracted_archive, files):
|