Dreambooth-Stable-Diffusion icon indicating copy to clipboard operation
Dreambooth-Stable-Diffusion copied to clipboard

'int' object has no attribute 'strip' (line 792)

Open AveCeasar opened this issue 3 years ago • 8 comments
trafficstars

Traceback (most recent call last): File "main.py", line 792, in ngpu = len(lightning_config.trainer.gpus.strip(",").split(',')) AttributeError: 'int' object has no attribute 'strip'

I'm using this fork: https://github.com/gammagec/Dreambooth-SD-optimized

AveCeasar avatar Sep 26 '22 17:09 AveCeasar

Make sure in the command that --gpus 0, has the comma after the zero.

SodyFX avatar Sep 26 '22 18:09 SodyFX

yeah, I've already tried it (saw a closed issue here). The full command looks like this:

python main.py --base D:\Dreambooth-SD-optimized\configs\stable-diffusion\v1-finetune_unfrozen.yaml -t --actual_resume D:\stable-diffusion-automatic\model.ckpt -n project01 --gpus 0, --data_root D:\Dreambooth-SD-optimized\training --reg_data_root D:\Dreambooth-SD-optimized\regimg --class_word girl

AveCeasar avatar Sep 26 '22 18:09 AveCeasar

Hi @AveCeasar, I had the same issue in Windows PowerShell and the solution was to replace --gpus 0, by --gpus "0,".

AcelisWeaven avatar Sep 27 '22 21:09 AcelisWeaven

Hi @AveCeasar, I had the same issue in Windows PowerShell and the solution was to replace --gpus 0, by --gpus "0,".

OMG I knew it was something stupid like this. Yup, this solved my issue also. Thanks!

RowanUnderwood avatar Oct 04 '22 16:10 RowanUnderwood

WOW

nice.

TemporalLabsLLC-SOL avatar Oct 05 '22 09:10 TemporalLabsLLC-SOL

Hi @AveCeasar, I had the same issue in Windows PowerShell and the solution was to replace --gpus 0, by --gpus "0,".

Where did you find this?

TemporalLabsLLC-SOL avatar Oct 05 '22 09:10 TemporalLabsLLC-SOL

Trial and error haha.

AcelisWeaven avatar Oct 06 '22 09:10 AcelisWeaven

@AcelisWeaven Thank you so much!!! (--gpu "0,") fixed it for me!

Ninja-Ferret avatar Oct 27 '22 01:10 Ninja-Ferret