Commit 4d19f3b7 authored by Melan's avatar Melan

Raise an assertion error if no training images have been found.

parent 368f4cc4
...@@ -82,6 +82,7 @@ class PersonalizedBase(Dataset): ...@@ -82,6 +82,7 @@ class PersonalizedBase(Dataset):
self.dataset.append(entry) self.dataset.append(entry)
assert len(self.dataset) > 1, "No images have been found in the dataset."
self.length = len(self.dataset) * repeats self.length = len(self.dataset) * repeats
self.initial_indexes = np.arange(self.length) % len(self.dataset) self.initial_indexes = np.arange(self.length) % len(self.dataset)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment