Skip to content

'ZeroDivisionError: division by zero' #60

@KouateMuhamed

Description

@KouateMuhamed

Hi,
I downloaded the MVTec dataset and am trying to launch the training using carpet images.
However, when I try to run the train.py script python3 train.py -d mvtec/carpet/ -a mvtecCAE -b 2 -l ssim -c grayscale, it returns me the reported error:

Found 0 images belonging to 2 classes. Found 0 images belonging to 2 classes. INFO:autoencoder.autoencoder:initiating learning rate finder to determine best learning rate. simulating training for different learning rates... this may take a few moments... Traceback (most recent call last): File "train.py", line 238, in <module> main(args) File "train.py", line 81, in main autoencoder.find_lr_opt(train_generator, validation_generator) File "/home/thomas/MVTec-Anomaly-Detection/autoencoder/autoencoder.py", line 191, in find_lr_opt restore_weights_only=True, File "/root/anaconda3/envs/mvtec/lib/python3.6/site-packages/ktrain/core.py", line 553, in lr_find verbose=verbose) File "/root/anaconda3/envs/mvtec/lib/python3.6/site-packages/ktrain/lroptimize/lrfinder.py", line 94, in find self.lr_mult = (end_lr / start_lr) ** (1 / num_batches) ZeroDivisionError: division by zero

How can I fix it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions