❗ ❗ ❗ This software is in the early development stage, it may bite your cat
ncnn implementation of Z-Image image generater.
zimage-ncnn-vulkan uses ncnn project as the universal neural network inference framework.
Download Windows/Linux/macOS Executable for Intel/AMD/NVIDIA/Apple-Silicon GPU
https://github.com/nihui/zimage-ncnn-vulkan/releases
This package includes all the binaries required. It is portable, so no CUDA or PyTorch runtime environment is needed :)
Download the z-image-turbo and z-image model folders to the same directory as the executable file
https://huggingface.co/nihui-szyl/z-image-ncnn/tree/main
Z-Image: An Efficient Image Generation Foundation Model with Single-Stream Diffusion Transformer
https://github.com/Tongyi-MAI/Z-Image
-
Minimum (Linux / macOS): 16GB RAM, any Vulkan capable GPU
-
Minimum (Windows):
Due to WDDM limitations: Vulkan applications can only use half of the system RAM.
The following condition shall be met: (Half of system RAM) + (GPU memory) >= 16GB
Examples of valid combinations:
- Any amount RAM, 16GB dedicated GPU
- 16GB RAM, 8GB dedicated GPU
- 24GB RAM, 4GB dedicated GPU
- 32GB RAM, any Vulkan capable GPU
-
Recommended: 32GB RAM, 16GB dedicated GPU with tensorcore/matrix hardware
zimage-ncnn-vulkan.exe -p "風的彷徨." -o output.pngUsage: zimage-ncnn-vulkan -p prompt -o outfile [options]...
-h show this help
-p prompt prompt (default=rand)
-n negative-prompt negative prompt (optional)
-o output-path output image path (default=out.png)
-s image-size image resolution (default=1024,1024)
-l steps denoise steps (default=auto)
-r random-seed random seed (default=rand)
-m model-path z-image model path (default=z-image-turbo)
-g gpu-id gpu device to use (-1=cpu, default=auto)If you encounter a crash or error, try upgrading your GPU driver:
- Intel: https://downloadcenter.intel.com/product/80939/Graphics-Drivers
- AMD: https://www.amd.com/en/support
- NVIDIA: https://www.nvidia.com/Download/index.aspx
- Clone this project with all submodules
git clone https://github.com/nihui/zimage-ncnn-vulkan.git
cd zimage-ncnn-vulkan
git submodule update --init --recursive --depth 1- Build with CMake
mkdir build
cd build
cmake ../src
cmake --build . -j 4
expand for full command
|
expand for full command
|
expand for full command
|
expand for full command
|
expand for full command
|
expand for full command
|
expand for full command
|
expand for full command
|
||
- https://github.com/Tencent/ncnn for fast neural network inference on ALL PLATFORMS
- https://github.com/futz12/ncnn_llm for BPE tokenizer
- https://github.com/webmproject/libwebp for encoding and decoding Webp images on ALL PLATFORMS
- https://github.com/libjpeg-turbo/libjpeg-turbo for encoding and decoding JPEG images on ALL PLATFORMS
- https://github.com/pnggroup/libpng for encoding and decoding PNG images on ALL PLATFORMS
- https://github.com/zlib-ng/zlib-ng for encoding and decoding PNG images on ALL PLATFORMS
- https://github.com/tronkko/dirent for listing files in directory on Windows







