Repository: huggingface/diffusers

Issue:
Quatered image produced, StableDiffusionPanoramaPipeline
### Describe the bug

Hi,
Anyone experienced the following when running the [multidifussion tutorial](https://huggingface.co/docs/diffusers/main/en/api/pipelines/panorama)? 
It generates a quater dolomites with the default setup but, correct one with `height=1024`


### Reproduction

Just did as shown in https://huggingface.co/docs/diffusers/main/en/api/pipelines/panorama

```
import torch
from diffusers import StableDiffusionPanoramaPipeline, DDIMScheduler

model_ckpt = "stabilityai/stable-diffusion-2-base"
scheduler = DDIMScheduler.from_pretrained(model_ckpt, subfolder="scheduler")
pipe = StableDiffusionPanoramaPipeline.from_pretrained(model_ckpt, scheduler=scheduler, torch_dtype=torch.float16)

pipe = pipe.to("cuda")

prompt = "a photo of the dolomites"
image = pipe(prompt).images[0]  #1/4
#image = pipe(prompt, height=1024).images[0] #looks ok.
image.save("dolomites.png")
```
![quater-dolomites](https://github.com/huggingface/diffusers/assets/5215050/f1b9bbb8-b4dd-4819-8df0-566b693448b1)


### Logs

_No response_

### System Info

- `diffusers` version: 0.18.0.dev0
- Platform: Linux-5.15.0-69-generic-x86_64-with-glibc2.27
- Python version: 3.9.16
- PyTorch version (GPU?): 1.13.0 (True)
- Huggingface_hub version: 0.15.1
- Transformers version: 4.29.2
- Accelerate version: 0.18.0
- xFormers version: not installed
- Using GPU in script?: yes
- Using distributed or parallel set-up in script?: no


Discussion:
cc @sayakpaul 
I can reproduce this on Colab. However installing from this commit https://github.com/huggingface/diffusers/commit/2f997f30ab660472561f5e1b5232d4f116315b1b, fixes the issue. 

```
!pip install -q git+https://github.com/huggingface/diffusers@2f997f30ab660472561f5e1b5232d4f116315b1b
```

So, my gut says it was likely introduced in https://github.com/huggingface/diffusers/pull/3546. 

Cc: @Isotr0py. Could you look into it once? 
I tested a94977b8b32b94ccd00d2f8f812aadb46764baba on Colab, and it works normally.
```
!pip install git+https://github.com/huggingface/diffusers@a94977b8b32b94ccd00d2f8f812aadb46764baba
```
![下载](https://github.com/huggingface/diffusers/assets/41363108/fd4b1f83-76e7-4b6e-a5e9-4a5b96e52dc5)

And this issue also appeared in `DPMSolverMultistepScheduler`, it seems that it's not about the schedulers but the blocks split.

So I think it was introduced in #3632, because we make some small changes to blocks split to support batched denoise. I may miss something in this PR.

I will check it out once I have spare time.
OK, I found it caused by a typo because of mistake... I will fix it soon.

Resolving patch:
diff --git a/src/diffusers/pipelines/stable_diffusion/pipeline_stable_diffusion_panorama.py b/src/diffusers/pipelines/stable_diffusion/pipeline_stable_diffusion_panorama.py
--- a/src/diffusers/pipelines/stable_diffusion/pipeline_stable_diffusion_panorama.py
+++ b/src/diffusers/pipelines/stable_diffusion/pipeline_stable_diffusion_panorama.py
@@ -463,7 +463,7 @@ def get_views(self, panorama_height, panorama_width, window_size=64, stride=8):
         panorama_height /= 8
         panorama_width /= 8
         num_blocks_height = (panorama_height - window_size) // stride + 1 if panorama_height > window_size else 1
-        num_blocks_width = (panorama_width - window_size) // stride + 1 if panorama_height > window_size else 1
+        num_blocks_width = (panorama_width - window_size) // stride + 1 if panorama_width > window_size else 1
         total_num_blocks = int(num_blocks_height * num_blocks_width)
         views = []
         for i in range(total_num_blocks):


Test patch: