Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
Megatron-LM
Commits
f2779b18
Commit
f2779b18
authored
Apr 16, 2020
by
Jared Casper
Browse files
Better error reporting when a dataset doesn't exist.
parent
f1f9fa0a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
megatron/data/indexed_dataset.py
megatron/data/indexed_dataset.py
+6
-1
No files found.
megatron/data/indexed_dataset.py
View file @
f2779b18
...
...
@@ -43,7 +43,8 @@ def infer_dataset_impl(path):
else
:
return
None
else
:
print
(
f
"Dataset path does not exist:
{
path
}
"
)
print
(
f
"Dataset does not exist:
{
path
}
"
)
print
(
"Path should be a basename that both .idx and .bin can be appended to get full filenames."
)
return
None
...
...
@@ -55,6 +56,10 @@ def make_builder(out_file, impl, vocab_size=None):
def
make_dataset
(
path
,
impl
,
skip_warmup
=
False
):
if
not
IndexedDataset
.
exists
(
path
):
print
(
f
"Dataset does not exist:
{
path
}
"
)
print
(
"Path should be a basename that both .idx and .bin can be appended to get full filenames."
)
return
None
if
impl
==
'infer'
:
impl
=
infer_dataset_impl
(
path
)
if
impl
==
'lazy'
and
IndexedDataset
.
exists
(
path
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment