Repository: stable-diffusion-webui
Issue: [Bug]: Batch size in img2img does not work properly with Poor man's outpainting
Labels: bug-report

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What happened?

When you attempt to increase the **batch size beyond 1** while performing outpainting using **Poor man's outpainting**, only **one image result** will be shown and saved to disk regardless of how much numbers you put.
I read about the same issue happened to outpainting mk2 and solved already so hope it can be solved too for this Poor man's outpainting, since it is doing better generation for me than mk2.

### Steps to reproduce the problem

1. Go to the img2img tab
2. Upload an image
3. Increase the batch size to 2 or more
4. Under scripts, Poor man's outpainting
5. Generate


### What should have happened?

The amount of generation images should be according to the set up batch size, and not only outputting one image all the time.

### Commit where the problem happens

https://github.com/AUTOMATIC1111/stable-diffusion-webui/commit/20ae71faa8ef035c31aa3a410b707d792c8203a3

### What Python version are you running on ?

Python 3.10.x

### What platforms do you use to access the UI ?

Windows

### What device are you running WebUI on?

Nvidia GPUs (RTX 20 above)

### What browsers do you use to access the UI ?

Google Chrome

### Command Line Arguments

```Shell
@echo off

set PYTHON="C:\Users\opd\AppData\Local\Programs\Python\Python310\python.exe"
set GIT=
set VENV_DIR=
set COMMANDLINE_ARGS=--xformers
git pull
call webui.bat
```


### List of extensions

https://github.com/DominikDoom/a1111-sd-webui-tagcomplete.git
https://github.com/pharmapsychotic/clip-interrogator-ext.git
https://github.com/adieyal/sd-dynamic-prompts.git
https://github.com/kohya-ss/sd-webui-additional-networks.git
https://github.com/thomasasfk/sd-webui-aspect-ratio-helper.git
https://github.com/Mikubill/sd-webui-controlnet.git
https://github.com/yankooliveira/sd-webui-photopea-embed
https://github.com/AUTOMATIC1111/stable-diffusion-webui-promptgen.git
https://github.com/innightwolfsleep/stable-diffusion-webui-randomize.git
https://github.com/AUTOMATIC1111/stable-diffusion-webui-rembg.git

### Console logs

```Shell
Already up to date.
venv "C:\FromOSBefore\AITools\stable-diffusion-webui\venv\Scripts\Python.exe"
Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug  1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
Version: v1.3.0
Commit hash: 20ae71faa8ef035c31aa3a410b707d792c8203a3
Installing requirements




Launching Web UI with arguments: --xformers
[AddNet] Updating model hashes...
0it [00:00, ?it/s]
[AddNet] Updating model hashes...
0it [00:00, ?it/s]
ControlNet v1.1.201
ControlNet v1.1.201
Loading weights [0cbf567c8c] from C:\FromOSBefore\AITools\stable-diffusion-webui\models\Stable-diffusion\aZovyaPhotoreal_v1.safetensors
Create LRU cache (max_size=16) for preprocessor results.
Create LRU cache (max_size=16) for preprocessor results.
Creating model from config: C:\FromOSBefore\AITools\stable-diffusion-webui\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
Running on local URL:  http://127.0.0.1:7860

To create a public link, set `share=True` in `launch()`.
Create LRU cache (max_size=16) for preprocessor results.
Startup time: 5.2s (import torch: 1.1s, import gradio: 0.8s, import ldm: 0.4s, other imports: 0.6s, load scripts: 1.5s, create ui: 0.5s, gradio launch: 0.2s).
DiffusionWrapper has 859.52 M params.
Applying optimization: xformers... done.
Textual inversion embeddings loaded(0):
Model loaded in 3.3s (load weights from disk: 0.6s, create model: 0.6s, apply weights to model: 0.4s, apply half(): 0.5s, move model to device: 0.4s, load textual inversion embeddings: 0.8s).
Poor man's outpainting will process a total of 2 images tiled as 2x2.
100%|██████████████████████████████████████████████████████████████████████████████████| 16/16 [00:04<00:00,  3.98it/s]
100%|██████████████████████████████████████████████████████████████████████████████████| 16/16 [00:03<00:00,  4.41it/s]
Total progress: 100%|██████████████████████████████████████████████████████████████████| 32/32 [00:07<00:00,  4.12it/s]
100%|██████████████████████████████████████████████████████████████████████████████████| 16/16 [00:09<00:00,  1.63it/s]
Total progress: 100%|██████████████████████████████████████████████████████████████████| 16/16 [00:09<00:00,  1.61it/s]
Poor man's outpainting will process a total of 2 images tiled as 2x2.██████████████████| 16/16 [00:09<00:00,  1.63it/s]
100%|██████████████████████████████████████████████████████████████████████████████████| 16/16 [00:03<00:00,  4.43it/s]
100%|██████████████████████████████████████████████████████████████████████████████████| 16/16 [00:03<00:00,  4.41it/s]
Total progress: 100%|██████████████████████████████████████████████████████████████████| 32/32 [00:07<00:00,  4.14it/s]
Total progress: 100%|██████████████████████████████████████████████████████████████████| 32/32 [00:07<00:00,  4.39it/s]
```


### Additional information

_No response_