I got error like this while training hypernetwork: "A tensor with all NaNs was produced in Unet. Thi

I got error like this while training hypernetwork:
"A tensor with all NaNs was produced in Unet. This could be either because there's not enough precision to represent the picture, or because your video card does not support half type. Try setting the "Upcast cross attention layer to float32" option in Settings > Stable Diffusion or using the --no-half commandline argument to fix this. Use --disable-nan-check commandline argument to disable this check."
I tried to add --no-half or set the "Upcast cross attention layer to float32" but it wont help. Wheni used --disable-nan-check then error disappeard BUT my samples are all black.
Was this page helpful?