Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X-only tiling? #259

Closed
nbs opened this issue Mar 13, 2024 · 5 comments
Closed

X-only tiling? #259

nbs opened this issue Mar 13, 2024 · 5 comments
Labels
enhancement New feature or request.

Comments

@nbs
Copy link

nbs commented Mar 13, 2024

I'd love to be able to specify only to do the seamless tiling on the X-axis only. If you need a use case, think backgrounds for things like a platformer game, something horizontally scrollable but doesn't try to put the ground in the sky as to be Y-tileable too.

Thanks!

@mcmonkey4eva mcmonkey4eva added the enhancement New feature or request. label Mar 13, 2024
@mcmonkey4eva
Copy link
Member

This is an interesting feature request and a cool idea, however I'm not sure how to actually achieve it in practice - internally tiling comes down to setting pytorch Conv2d padding mode to circular, and they don't appear to have any form of "x_circular but y none" type of options, nor any obvious way to inject that short of... maybe totally replacing the Conv2d code with alternate code that call's a custom pad?

@nbs
Copy link
Author

nbs commented Mar 14, 2024

Thanks for your response! I've heard as much, from asking around the sdnext repo.

I think InvokeAI is the only project that has figured out an implementation:

image

https://github.com/invoke-ai/InvokeAI/blob/main/invokeai/backend/stable_diffusion/seamless.py

Of course I'd prefer to use Swarm though.

The dream is actually to axis-tile AND upscale at the same time, as seen in this longstanding issue in AUTO1111 there's a few of us wanting it:

AUTOMATIC1111/stable-diffusion-webui#3590

I imagine this is very low on the priority list but thanks for your consideration nonetheless!

@mcmonkey4eva
Copy link
Member

Oh, yep, they do exactly what I was thinking - injecting and replacing the conv2d code with an alternate handler

mcmonkey4eva added a commit that referenced this issue May 20, 2024
@mcmonkey4eva
Copy link
Member

the seamless tileable param now has X-Only and Y-Only options

@nbs
Copy link
Author

nbs commented May 21, 2024

Huge! Thank you so much. Haven't been able to test it yet but will let you know if I run into anything. Thanks again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request.
Projects
None yet
Development

No branches or pull requests

2 participants