AUTOMATIC1111 / stable-diffusion-webui

Stable Diffusion web UI
GNU Affero General Public License v3.0
140.37k stars 26.57k forks source link

[Bug]: "Error training embedding Traceback" - when training Embedding or Hypernetwork #13439

Open B-Hard opened 1 year ago

B-Hard commented 1 year ago

Is there an existing issue for this?

What happened?

When training a hypernetwork with a dataset and Hypernetwork.txt as template, stable diffusion throws the following error: ** Error training embedding Traceback (most recent call last): File "C:\AI\stable-diffusion-webui\modules\textual_inversion\textual_inversion.py", line 593, in train_embedding p.sampler_name = sd_samplers.samplers[preview_sampler_index].name TypeError: list indices must be integers or slices, not str

Training a hypernetwork works fine in v 1.5. This is an v1.6 issue.

Could make it work partly when using this fix: https://github.com/AUTOMATIC1111/stable-diffusion-webui/commit/de5bb4ca88df44362c9263de7334b30156540e21

Also check this previous BUG report https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/13080

Steps to reproduce the problem

  1. Go to Training
  2. Press Training hypernetwork with a dataset and some prompt in text2img
  3. Press Training Hypernetwork or embedding

What should have happened?

Successfull starting the training/learning process of a given dataset

Sysinfo

Windows 11 x64

What browsers do you use to access the UI ?

Edge, Chrome

Console logs

`** Error training embedding Traceback (most recent call last): File "C:\AI\stable-diffusion-webui\modules\textual_inversion\textual_inversion.py", line 593, in train_embedding p.sampler_name = sd_samplers.samplers[preview_sampler_index].name TypeError: list indices must be integers or slices, not str`

Additional information

Does not happen in V1.5

ghzgod commented 11 months ago

I am noticing this exact issue as well.

oliverboyd commented 7 months ago

same issue... v1.7

B-Hard commented 5 months ago

Try using the DEV branch.