Views
No views yet

1from lens_mlx.pipeline_mlx import LensPipeline # github.com/xocialize/lens-mlx
2
3# `base` = a microsoft/Lens snapshot (tokenizer + GPT-OSS encoder + FLUX.2 VAE).
4pipe = LensPipeline.from_pretrained(base, dit_repo="mlx-community/Lens-Turbo-3.8B-bf16")
5img = pipe("A serene lake below snow-capped mountains, golden hour.",
6 height=1024, width=1024, num_inference_steps=4, guidance_scale=1.0, seed=42)
7img.save("out.png")Tip: page weights into memory before the first forward (mx.evalthe params) when loading from slow/external storage, to avoid a Metal command-buffer watchdog timeout at large sizes.