1inkusFace commited on
Commit
1ac1e57
·
verified ·
1 Parent(s): 5d6dc06

Update pipeline_stable_diffusion_3_ipa.py

Browse files
Files changed (1) hide show
  1. pipeline_stable_diffusion_3_ipa.py +1 -1
pipeline_stable_diffusion_3_ipa.py CHANGED
@@ -1208,7 +1208,7 @@ class StableDiffusion3Pipeline(DiffusionPipeline, SD3LoraLoaderMixin, FromSingle
1208
  stacked_image_embeds = torch.stack(image_prompt_embeds_list)
1209
 
1210
  # 2. Calculate the mean of the stacked embeddings
1211
- average_image_embed = torch.mean(stacked_image_embeds, dim=0).unsqueeze(0) # Add batch dimension after averaging
1212
 
1213
  # 3. Create a tensor of zeros with the same shape as the averaged embedding
1214
  zeros_tensor = torch.zeros_like(average_image_embed)
 
1208
  stacked_image_embeds = torch.stack(image_prompt_embeds_list)
1209
 
1210
  # 2. Calculate the mean of the stacked embeddings
1211
+ average_image_embed = torch.mean(stacked_image_embeds, dim=0) #.unsqueeze(0) # Add batch dimension after averaging
1212
 
1213
  # 3. Create a tensor of zeros with the same shape as the averaged embedding
1214
  zeros_tensor = torch.zeros_like(average_image_embed)