Instructions to use vidfom/Ltx-3 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use vidfom/Ltx-3 with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf vidfom/Ltx-3:UD-Q4_K_XL # Run inference directly in the terminal: llama cli -hf vidfom/Ltx-3:UD-Q4_K_XL
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf vidfom/Ltx-3:UD-Q4_K_XL # Run inference directly in the terminal: llama cli -hf vidfom/Ltx-3:UD-Q4_K_XL
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf vidfom/Ltx-3:UD-Q4_K_XL # Run inference directly in the terminal: ./llama-cli -hf vidfom/Ltx-3:UD-Q4_K_XL
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf vidfom/Ltx-3:UD-Q4_K_XL # Run inference directly in the terminal: ./build/bin/llama-cli -hf vidfom/Ltx-3:UD-Q4_K_XL
Use Docker
docker model run hf.co/vidfom/Ltx-3:UD-Q4_K_XL
- LM Studio
- Jan
- Ollama
How to use vidfom/Ltx-3 with Ollama:
ollama run hf.co/vidfom/Ltx-3:UD-Q4_K_XL
- Unsloth Desktop
- Docker Model Runner
How to use vidfom/Ltx-3 with Docker Model Runner:
docker model run hf.co/vidfom/Ltx-3:UD-Q4_K_XL
- Lemonade
How to use vidfom/Ltx-3 with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull vidfom/Ltx-3:UD-Q4_K_XL
Run and chat with the model
lemonade run user.Ltx-3-UD-Q4_K_XL
List all available models
lemonade list
- Atomic Chat
Download ComfyUI/custom_nodes/ComfyUI_LayerStyle/py/batch_selector.py from vidfom/Ltx-3: direct link, hf CLI and curl.
- Browser
- Download file 1.93 kB
-
https://huggingface.co/vidfom/Ltx-3/resolve/main/ComfyUI/custom_nodes/ComfyUI_LayerStyle/py/batch_selector.py
- Command line
-
hf download hf://vidfom/Ltx-3/ComfyUI/custom_nodes/ComfyUI_LayerStyle/py/batch_selector.py
-
curl -L -o batch_selector.py https://huggingface.co/vidfom/Ltx-3/resolve/main/ComfyUI/custom_nodes/ComfyUI_LayerStyle/py/batch_selector.py
1.93 kB
| import torch | |
| from .imagefunc import log, pil2tensor,image2mask, extract_numbers | |
| from PIL import Image | |
| class BatchSelector: | |
| def __init__(self): | |
| self.NODE_NAME = 'BatchSelector' | |
| pass | |
| def INPUT_TYPES(self): | |
| return { | |
| "required": { | |
| "select": ("STRING", {"default": "0,"},), | |
| }, | |
| "optional": { | |
| "images": ("IMAGE",), # | |
| "masks": ("MASK",), # | |
| } | |
| } | |
| RETURN_TYPES = ("IMAGE", "MASK",) | |
| RETURN_NAMES = ("image", "mask",) | |
| FUNCTION = 'batch_selector' | |
| CATEGORY = '😺dzNodes/LayerUtility/SystemIO' | |
| def batch_selector(self, select, images=None, masks=None | |
| ): | |
| ret_images = [] | |
| ret_masks = [] | |
| empty_image = pil2tensor(Image.new("RGBA", (64, 64), (0, 0, 0, 0))) | |
| empty_mask = image2mask(Image.new("L", (64, 64), color="black")) | |
| indexs = extract_numbers(select) | |
| for i in indexs: | |
| if images is not None: | |
| if i < len(images): | |
| ret_images.append(images[i].unsqueeze(0)) | |
| else: | |
| ret_images.append(images[-1].unsqueeze(0)) | |
| if masks is not None: | |
| if i < len(masks): | |
| ret_masks.append(masks[i].unsqueeze(0)) | |
| else: | |
| ret_masks.append(masks[-1].unsqueeze(0)) | |
| if len(ret_images) == 0: | |
| ret_images.append(empty_image) | |
| if len(ret_masks) == 0: | |
| ret_masks.append(empty_mask) | |
| log(f"{self.NODE_NAME} Processed {len(ret_images)} image(s).", message_type='finish') | |
| return (torch.cat(ret_images, dim=0), torch.cat(ret_masks, dim=0),) | |
| NODE_CLASS_MAPPINGS = { | |
| "LayerUtility: BatchSelector": BatchSelector | |
| } | |
| NODE_DISPLAY_NAME_MAPPINGS = { | |
| "LayerUtility: BatchSelector": "LayerUtility: Batch Selector" | |
| } |