Others

(Scuffed) 4-Step Image Decensor Guide

файл на civitaiстраница на civitai

In theory this should work on almost all kinds of visual censorship, including cases where areas are completely blocked off by clothing! Read below.

All images shown in this post are AI-generated! No works of real life artists were used.

You don't need to download this "model", but it contains an example. Just have a read if you don't need that.

If you find this guide helpful please leave a like~!

Prerequisites

Step 1

You need the image you want to decensor, it could range from a mosaic censor to outright clothing covering it; open it in your preferred image editor program.

In this example we will decensor the image by removing the panties, which is one of the hardest case scenarios you'll encounter for decensoring.

Step 2

Draw a crappy sketch on the part you want to be decensored in your preferred image editor and save. You may skip this step and head to step 3 if the censored part is gaussian blur or mosaic that isn't too heavy.

It doesn't matter that much even if the colors are mostly flat and the details are mostly gone, the general color and approximate shape is important. However, some shading (especially on different body segments, which I kind of failed to do here) would improve results in step 3.

Step 3

Okay, here's the fun part.

Plug the image from step 2 to inpainting under the img2img tab, then draw an inpaint mask on the sketched part. It should completely cover your sketched area.

Set mask blur to a low value (below 12) and masked padding to a high value (no less than 128, depending on how big your original image is). Set inpainting area to "only masked" and denoising to a moderate value (0.4~0.6 would do).

Width and height setting should be 768x768 or 512x512, or whatever really; just don't make it too big nor small. Note that the aspect ratio isn't dependent on the image as inpainting area is set to "only masked".

For prompts, put whatever that is supposed to be in the masked area is (like pussy to positive prompt for this example) and don't forget to add quality control prompts (like masterpiece, best quality in positive prompts and worst quality, bad anatomy + whatever to negative prompts, you get my point).

Note: you could try inpainting area to "whole picture" if you cannot get good results even with high padding value; keep that in mind that if you do this you'll have to set width and height to match the original image's ones.

If you get a black spot instead of anything else on your masked area after hitting generate, put --no-half-vae in your webui-user.bat file's launch parameters, reopen webui, then try again.

When that's all done, generate repeatedly until you get a result you consider good enough.

This result should have decensored the image, but the image will have seams between the inpainted area and areas that are not, hence step 4 is needed.

Step 4

Now for the cleanup.

This step may be unnecessary if your result from step 3 looks clean enough, but that's unlikely.

Plug the image from step 3 back to inpainting, draw an inpainting mask at and around the place you did img2img in step 3.

Set mask blur to a high value (64) and mask padding to a moderate value (64~128). set inpainting area to "only masked" and denoising to a low value (0.25~0.35).

Don't forget about the width and height like in step 3.

For prompts, put whatever that is supposed to be in the masked area is and add quality control prompts, similar to step 3.

When you're ready, generate until you get a result you consider good enough.

After this step the seams should be mostly gone, and you are done!

Remarks

Let me know if you're confused about a step, or anything really. That's all for now, have fun~

Тэги: inpaintingimg2imgguidecensor
SHA256: ACCEE810CFAD389535FDA71CFB2A8F8E7DD80D9C3E3B6CC15BF6E860C167903D

ComfyUI - FaceRestore Node

файл на civitaiстраница на civitai

FaceRestore node for ComfyUI. To install copy the facerestore directory from the zip to the custom_nodes directory in ComfyUI.

I bodged this together in an afternoon. You might need to pip install a package if it doesn't work at first.

You'll need codeformer-v0.1.0.pth or GFPGANv1.4.pth in your models/upscale_models directory. The node uses another model for face detection which it will download and put in models/facedetection

Тэги: custom nodecomfyuinodestool
SHA256: D31CF39A61166BA57595EB973201AB2D425A9D8F3C7A1A76C84ED22B22580A07

webui-user.bat Fix Error

файл на civitaiстраница на civitai

webui-user.bat Fix Error

https://www.pixiv.net/artworks/107731864

My setting:

@echo off

set PYTHON="C:\Users\admin\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Python 3.10\Python 3.10 (64-bit).lnk"
set GIT=
set VENV_DIR=
set COMMANDLINE_ARGS=--xformers --no-half-vae --no-half --theme dark --disable-safe-unpickle
git pull
call webui.bat

Тэги: tool
SHA256: 8294159F7713EDD7FB42D6F06FB1BC01713F4294E342AB33897CC953DD7AFB9D