-
Notifications
You must be signed in to change notification settings - Fork 470
Seamless texture generation support for qwen image, z-image, and flux #914
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
base: master
Are you sure you want to change the base?
Conversation
|
Some conflicts, lemme resolve those... |
|
Nice Work! Once ggml merges the circular-pad changes, I will merge this PR. |
|
llama.cpp PR merged already! |
|
Needs to be modified slightly bc you can do it only circular pad no circular conv |
|
In particular like this: I can clean up this PR to that on wednesday |
|
I think we can add a field in GGMLRunnerContext to control whether circular padding is used. |
|
looked into this, though it was merged into llama.cpp, we'll need to wait for ggml to be synced with llama.cpp's ggml (it seems to only be synced every few weeks), or alternatively adjust the reference to point to llama.cpp's ggml folder instead of ggml |
|
@ggerganov any chance for a GGML sync? |
|
It's synced now - thanks |
|
in progress, wait a few min... |
|
Okay it is working for qwen image, should also work for other models but I haven't tested them yet, anyone else feel free to |
|
Works for z-image too now
(You can use this to test out seamless textures) |
|
Is there any way to make it circular only horizontally? To generate equirectangular 360 panoramas, for example? |
In principle it would be fairly easy, but does require an additional pr to llama.cpp |
You can try it now, but I think my implementation for chroma isn't quite right/we're still missing something because it's mostly seamless but still a little blurry around borders |
|
Ok there's some source of non-circular I'm still missing for chroma, it mostly tiles is a little fuzzy at the edges (maybe something with the vae?), but otherwise things are refactored into -circularx or -circulary or -circular for qwen, z-image, and chroma/flux |
|
This is just in time for me wanting to get a seamless background tile for my blog ;) |











Adds support for qwen image to generate seamless textures, using a
--circularflag. Edit: Also includes a--circularxand--circularyif you want only tiling on those axesRequires this PR ggml-org/ggml#1374 (Edit: see ggml-org/llama.cpp#16985) for ggml that adds a "circular" mode that can be used.
I also had to tweak rope so the period of the sinusods would evenly tile.