Skip to content

Commit

Permalink
Initial workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
fofr committed Mar 11, 2024
1 parent fc2a2ef commit 5217d16
Show file tree
Hide file tree
Showing 7 changed files with 945 additions and 1,223 deletions.
25 changes: 6 additions & 19 deletions README.md
@@ -1,14 +1,14 @@
# face-to-many
# become-image

Turn any face into 3D, pixel art, video game, claymation or toy.
Adapt any picture of a face into another image

Run this model on Replicate:

https://replicate.com/fofr/face-to-many
https://replicate.com/fofr/become-image

Or run it in ComfyUI:

https://github.com/fofr/cog-face-to-many/blob/main/face-to-many-ui.json
https://github.com/fofr/cog-become-image/blob/main/become-image-ui.json

You’ll need these custom nodes:

Expand All @@ -18,28 +18,15 @@ You’ll need these custom nodes:
- [ComfyUI Essentials](https://github.com/cubiq/ComfyUI_essentials/tree/c9236fe)
- [Efficiency Nodes ComfyUI](https://github.com/jags111/efficiency-nodes-comfyui/tree/1ac5f18)

![Arnold](https://replicate.delivery/pbxt/R1ayGe5efoQbaoRzgDEJdLsIZ20lWRiprvoW1F4uKAZIha6kA/ComfyUI_00001_.png)

## Loras

The 3D, video game, pixel art, claymation and toy loras are all made by artificialguybr. If you like them you can make a donation to their Patreon or Ko-fi:

- https://www.patreon.com/user?u=81570187
- https://ko-fi.com/artificialguybr

Or follow him on Twitter:

https://twitter.com/artificialguybr

## Developing locally

Clone this repository:

```sh
git clone --recurse-submodules https://github.com/fofr/cog-face-to-many.git
git clone --recurse-submodules https://github.com/fofr/cog-become-image.git
```

Run the [following script](https://github.com/fofr/cog-comfyui/blob/main/scripts/clone_plugins.sh) to install all the custom nodes:
Run the [following script](https://github.com/fofr/cog-become-image/blob/main/scripts/clone_plugins.sh) to install all the custom nodes:

```sh
./scripts/clone_plugins.sh
Expand Down
295 changes: 295 additions & 0 deletions become-image-api.json
@@ -0,0 +1,295 @@
{
"2": {
"inputs": {
"ckpt_name": "albedobaseXL_v13.safetensors",
"vae_name": "Baked VAE",
"clip_skip": -1,
"lora_name": "None",
"lora_model_strength": 1,
"lora_clip_strength": 1,
"positive": "a painting of a woman",
"negative": "nsfw, nude, ugly, broken, watermark",
"token_normalization": "none",
"weight_interpretation": "comfy",
"empty_latent_width": 1024,
"empty_latent_height": 1024,
"batch_size": 1,
"cnet_stack": [
"79",
0
]
},
"class_type": "Efficient Loader",
"_meta": {
"title": "Efficient Loader"
}
},
"5": {
"inputs": {
"filename_prefix": "ComfyUI",
"images": [
"76",
0
]
},
"class_type": "SaveImage",
"_meta": {
"title": "Save Image"
}
},
"22": {
"inputs": {
"image": "download.webp",
"upload": "image"
},
"class_type": "LoadImage",
"_meta": {
"title": "Load Image"
}
},
"24": {
"inputs": {
"control_net_name": "depth-zoe-xl-v1.0-controlnet.safetensors"
},
"class_type": "ControlNetLoader",
"_meta": {
"title": "Load ControlNet Model"
}
},
"35": {
"inputs": {
"instantid_file": "instantid-ip-adapter.bin"
},
"class_type": "InstantIDModelLoader",
"_meta": {
"title": "Load InstantID Model"
}
},
"36": {
"inputs": {
"provider": "CPU"
},
"class_type": "InstantIDFaceAnalysis",
"_meta": {
"title": "InstantID Face Analysis"
}
},
"40": {
"inputs": {
"control_net_name": "instantid-controlnet.safetensors"
},
"class_type": "ControlNetLoader",
"_meta": {
"title": "Load ControlNet Model"
}
},
"41": {
"inputs": {
"weight": 1,
"start_at": 0,
"end_at": 1,
"instantid": [
"35",
0
],
"insightface": [
"36",
0
],
"control_net": [
"40",
0
],
"image": [
"67",
0
],
"model": [
"2",
0
],
"positive": [
"2",
1
],
"negative": [
"2",
2
]
},
"class_type": "ApplyInstantID",
"_meta": {
"title": "Apply InstantID"
}
},
"49": {
"inputs": {
"preprocessor": "Zoe-DepthMapPreprocessor",
"resolution": 1024,
"image": [
"67",
0
]
},
"class_type": "AIO_Preprocessor",
"_meta": {
"title": "AIO Aux Preprocessor"
}
},
"51": {
"inputs": {
"pixels": [
"67",
0
],
"vae": [
"2",
4
]
},
"class_type": "VAEEncode",
"_meta": {
"title": "VAE Encode"
}
},
"67": {
"inputs": {
"width": 1024,
"height": 1024,
"interpolation": "nearest",
"keep_proportion": true,
"condition": "always",
"image": [
"22",
0
]
},
"class_type": "ImageResize+",
"_meta": {
"title": "🔧 Image Resize"
}
},
"75": {
"inputs": {
"seed": 652860453823882,
"steps": 20,
"cfg": 3,
"sampler_name": "dpmpp_sde_gpu",
"scheduler": "karras",
"denoise": 1,
"model": [
"81",
0
],
"positive": [
"41",
1
],
"negative": [
"41",
2
],
"latent_image": [
"51",
0
]
},
"class_type": "KSampler",
"_meta": {
"title": "KSampler"
}
},
"76": {
"inputs": {
"samples": [
"75",
0
],
"vae": [
"2",
4
]
},
"class_type": "VAEDecode",
"_meta": {
"title": "VAE Decode"
}
},
"79": {
"inputs": {
"strength": 0.8,
"start_percent": 0,
"end_percent": 1,
"control_net": [
"24",
0
],
"image": [
"49",
0
]
},
"class_type": "Control Net Stacker",
"_meta": {
"title": "Control Net Stacker"
}
},
"80": {
"inputs": {
"ipadapter_file": "ip-adapter-plus_sdxl_vit-h.safetensors"
},
"class_type": "IPAdapterModelLoader",
"_meta": {
"title": "Load IPAdapter Model"
}
},
"81": {
"inputs": {
"weight": 0.75,
"noise": 0.3,
"weight_type": "original",
"start_at": 0,
"end_at": 1,
"unfold_batch": false,
"ipadapter": [
"80",
0
],
"clip_vision": [
"82",
0
],
"image": [
"83",
0
],
"model": [
"41",
0
]
},
"class_type": "IPAdapterApply",
"_meta": {
"title": "Apply IPAdapter"
}
},
"82": {
"inputs": {
"clip_name": "CLIP-ViT-H-14-laion2B-s32B-b79K.safetensors"
},
"class_type": "CLIPVisionLoader",
"_meta": {
"title": "Load CLIP Vision"
}
},
"83": {
"inputs": {
"image": "fc,550x550,white-1110626934.jpg",
"upload": "image"
},
"class_type": "LoadImage",
"_meta": {
"title": "Load Image"
}
}
}

2 comments on commit 5217d16

@Enchantedyu
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

![Screenshot_20240326_001515_com ss android ugc aweme](https://github.com/fofr/cog-become-image/assets/164910403/dda220f0-db6c-49d6-b981-d37b2pixelated glitchart of close-up of (subject}, ps1 playstation psx gamecube game radioactive dreams screencapture, bryce 3d16131b3)

@Paradoxc123
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uploading DSC08850.jpeg…

Please sign in to comment.