The Pixel Sort Glitch Effect Image Transformation workflow in ComfyUI is designed to transform ordinary images into visually striking glitch art using a pixel sorting algorithm. This technique rearranges pixels based on their brightness, creating a smeared, glitch-like appearance. The workflow leverages the FL_PixelSort node, which allows users to control the direction and intensity of the effect by adjusting parameters such as rotation and threshold. The LoadImage node is used to import the image to be transformed, and the SaveImage node is employed to export the final stylized image. This workflow is particularly useful for artists and designers looking to add a unique, abstract aesthetic to their digital artwork without requiring specific models, making it versatile and easy to use.
API
Use this workflow from code
Every Comfy workflow is a JSON graph. The payload below is this workflow, exactly as ComfyUI runs it — fetch it from the URL, keep it in version control, or load it in ComfyUI and run it node by node.
GET https://comfy.org/workflows/download/1eb49d4d5811.jsonFetching workflow JSON…
Run it from Python or TypeScript with the Comfy SDK. The same code targets Comfy Cloud or a ComfyUI you host yourself — only the base URL changes.
# Install (beta)
pip install comfy-sdk # Python
npm i @comfyorg/sdk # TypeScript
# Run "Pixel Sort Glitch Effect Image Transformation" (Python)
from comfy_sdk import Comfy
client = Comfy(api_key="comfyui-...")
# This workflow, exported in API format (see note below)
wf = client.workflows.from_file("templates_purz_pixel_sort_image_api.json")
asset = client.assets.from_file("input.png")
wf.set_input("2", "image", asset) # LoadImage
job = client.run(wf)
for output in job.get_outputs("3"): # SaveImage
output.to_file(output.name)The SDK takes a workflow in API format: open this workflow in ComfyUI and use File → Export Workflow (API). API access requires a Comfy Cloud plan with an API key. SDK docs · Get an API key
FAQ
















