Derp. ImageStore.__init__ already iterates fully :)
This commit is contained in:
parent
925eacf374
commit
de221ea42e
|
@ -169,10 +169,6 @@ class Validation():
|
||||||
self.validate = self.__validate
|
self.validate = self.__validate
|
||||||
print("Validation: Standard")
|
print("Validation: Standard")
|
||||||
|
|
||||||
def completed(self) -> None:
|
|
||||||
self.validate = self.__no_op
|
|
||||||
return print('Validation complete. Skipping further validation.')
|
|
||||||
|
|
||||||
def __validate(self, fp: str) -> bool:
|
def __validate(self, fp: str) -> bool:
|
||||||
try:
|
try:
|
||||||
Image.open(fp)
|
Image.open(fp)
|
||||||
|
@ -725,13 +721,10 @@ def main():
|
||||||
collate_fn=dataset.collate_fn
|
collate_fn=dataset.collate_fn
|
||||||
)
|
)
|
||||||
|
|
||||||
# Validate dataset and perform possible migration
|
# Migrate dataset
|
||||||
|
if args.resize and args.data_migration:
|
||||||
for _, batch in enumerate(train_dataloader):
|
for _, batch in enumerate(train_dataloader):
|
||||||
continue
|
continue
|
||||||
|
|
||||||
store.validator.completed()
|
|
||||||
|
|
||||||
if args.resize and args.data_migration:
|
|
||||||
print(f"Completed resize and migration to '{args.dataset}_cropped' please relaunch the trainer without the --resize argument and train on the migrated dataset.")
|
print(f"Completed resize and migration to '{args.dataset}_cropped' please relaunch the trainer without the --resize argument and train on the migrated dataset.")
|
||||||
exit(0)
|
exit(0)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue