Negative Embeddings - ULTRA QUALITY Trick for A1111

Olivio Sarikas
14 Apr 202306:33

TLDRThis informative video offers two valuable tricks to enhance the quality of AI-generated images. The first trick involves using 'negative embeddings,' which are trained on undesirable image attributes to improve results by incorporating them into a negative prompt. The process includes downloading specific embeddings and applying them with a weight, such as 0.8, to refine the image. The second trick focuses on upscaling images for better quality. It involves rendering an image at double the original resolution, using a denoise strength of 0.25, and then sharpening the image in photo editing software to bring out more texture and detail. Finally, the video suggests re-rendering the sharpened image with face restore turned off to maintain the optimized facial features. The presenter warns against over-sharpening, which can create problematic edges, and advises on how to correct them. These techniques aim to provide clearer and more detailed AI renders.

Takeaways

  • ๐Ÿ” Negative embeddings are used to improve AI renders by training an embedding on what the image should not look like and including it in the negative prompt.
  • ๐ŸŽจ The negative prompt can address various aspects such as art style, prompt, and hands to fix issues beyond what the main prompt can achieve.
  • ๐Ÿ“š To use negative embeddings, download them into the 'embeddings' folder of your AI application and refer to them by name in the negative prompt.
  • ๐Ÿ“ˆ A weight (often 0.8) is applied to the negative embeddings to balance their influence on the final render.
  • ๐Ÿ“ฑ Upscaling can be enhanced by first rendering an image at a lower resolution and then using an image-to-image upscaling method.
  • ๐Ÿ” After upscaling, use photo editing software to apply a sharpening filter (e.g., Unsharpen Mask with a setting of 1 pixel and 0%) to bring out more texture and detail.
  • ๐Ÿ’ก It is important to avoid over-sharpening, which can introduce unwanted bright edges in the image.
  • ๐Ÿ› ๏ธ If over-sharpening occurs, use an eraser tool to remove the highlighted edges and restore the original, less sharp appearance in those areas.
  • ๐Ÿ”„ When re-importing the sharpened image into the AI application, turn off face restore to maintain the optimized facial details.
  • โš™๏ธ Keep the same settings for the AI application except for turning off face restore to ensure the rest of the image retains its enhanced quality.
  • ๐Ÿ‘€ The final render will show clearer details, especially in areas like fabric, background foliage, and armor due to the AI having more information to work with.
  • ๐Ÿ‘ Leave a like if you enjoyed the video and found the tips helpful, and look out for more content in the future.

Q & A

  • What is a negative embedding in the context of AI renders?

    -A negative embedding is a model trained on undesirable image characteristics to guide the AI rendering process away from producing such features. It's used in the negative prompt to improve the quality of AI-generated images.

  • How does the negative embedding help in fixing image issues beyond the prompt?

    -Negative embeddings can address specific issues like art style, prompt accuracy, and hand positioning. By including them in the negative prompt, they can correct image flaws that might not be resolved by the prompt alone.

  • What is the process of using negative embeddings in an AI render?

    -To use negative embeddings, one must download the embedding models and place them into the 'embeddings' folder of the AI render software. Then, the name of the embedding is used in the negative prompt, enclosed in pointy brackets without the '.pt' extension, and often with a weight applied (e.g., ':0.8').

  • How does upscaling affect the quality of an AI-rendered image?

    -Upscaling can significantly improve the quality of an image by increasing its resolution. The process involves rendering the image at a higher resolution and using specific techniques or software to enhance details without introducing artifacts.

  • What is the trick to get the last bit of quality out of an image during upscaling?

    -The trick involves rendering the image at double the original resolution, using a denoise strength that allows for some changes, and then sharpening the image in photo editing software before re-importing it into the AI render software with face restore turned off.

  • Why is it important to avoid over-sharpening when enhancing an image?

    -Over-sharpening can introduce unwanted artifacts, such as bright edges, which can detract from the image's quality. It's crucial to find a balance where the image is sharpened enough to enhance details but not so much that it introduces these artifacts.

  • How can one correct over-sharpening issues in an image?

    -If over-sharpening occurs, particularly around edges, one can use photo editing software to manually erase or reduce the sharpness of those areas to restore the original, less highlighted edge.

  • What is the benefit of using DPM plus plus, SDE Keras for rendering?

    -DPM plus plus, SDE Keras is a rendering technique that can be used to produce high-quality images. It allows for control over the rendering process, such as the number of steps and denoise strength, to achieve the desired level of detail and noise reduction.

  • Why is it recommended to save the sharpened image as a PNG?

    -Saving the sharpened image as a PNG is recommended to avoid the introduction of compression artifacts that can occur with the JPEG format. PNG preserves the image quality without degradation.

  • How does turning off face restore after the initial rendering affect the final image?

    -Turning off face restore after the initial rendering helps to maintain the clarity and details of the face that were optimized in the first pass. It prevents the face from being slightly blurred during the second rendering process.

  • What are the potential issues with using negative embeddings?

    -While negative embeddings can improve image quality, they must be carefully managed. Incorrect use or over-reliance on negative embeddings could potentially lead to a loss of desired features or an overly stylized result that doesn't align with the creator's vision.

  • How does the process of loading a sharpened image back into the AI render software affect the final render?

    -Loading a sharpened image back into the AI render software provides the AI with more detailed information to work with, which can result in a clearer and more detailed final render, especially in areas like fabric, background foliage, and armor details.

Outlines

00:00

๐Ÿ–ผ๏ธ Enhancing AI Render Quality with Negative Embeddings and Upscaling

The video begins with the host sharing two techniques to improve the quality of AI-generated images. The first technique involves using negative embeddings, which are trained on undesirable image characteristics to prevent such outcomes. This method can refine various aspects like art style, prompt, and hand positioning. The host demonstrates how to apply these embeddings by downloading them into the 'embeddings' folder and using their names in negative prompts with a weight of 0.8. The second trick focuses on upscaling, where the host uses an image-to-image upscaling method with a specific sequence: doubling the resolution, enabling face restore, and applying a denoise strength of 0.25. After the initial render, the image is sharpened in photo editing software to enhance texture details. The sharpened image is then re-uploaded for a second render with face restore turned off to maintain the optimized face details. The host compares the original and the new sharpened versions, noting the improved clarity and detail, especially in fabric and background elements. The video concludes with a caution about over-sharpening and a suggestion to manually edit out any highlighted edges that may appear.

05:01

๐Ÿ‘Œ Fine-Tuning Sharpness and Avoiding Over-Sharpening Issues

The second paragraph further elaborates on the upscaling process and the importance of managing sharpness effectively. The host points out that over-sharpening can lead to problematic bright edges, as demonstrated by an example on the right side of a hat. To rectify this, they recommend keeping both the original and the sharpened images open for comparison and using an eraser tool to remove the highlighted edge. This ensures that the original, less sharp, part of the image is restored. The host also advises viewers to look out for and reduce highlighted edges during the sharpening process to avoid over-sharpening. They suggest rendering the image more frequently if needed to maintain quality. The video ends with a call to action for viewers to like the video if they enjoyed it and a farewell note, inviting viewers to stay tuned for more content.

Mindmap

Keywords

๐Ÿ’กNegative Embeddings

Negative embeddings refer to a technique used in artificial intelligence image processing where embeddings trained on undesirable attributes are utilized to improve the quality of generated images. In the context of the video, negative embeddings are applied to exclude specific unwanted elements like poor art styles or errors in hand representations, thereby enhancing the final image output.

๐Ÿ’กAI Renders

AI renders involve creating images or graphics using artificial intelligence technologies. The video discusses how to enhance the quality of these renders by using specific techniques and settings, such as negative embeddings and upscaling methods, to produce clearer and more detailed images.

๐Ÿ’กUpscaling

Upscaling in the context of image processing refers to the technique of increasing the resolution of an image using AI tools. The video details a method of doubling the resolution of an image to improve its quality, followed by additional steps like sharpening to enhance texture and detail in the upscaled image.

๐Ÿ’กImage to Image

Image to Image refers to an AI tool or technique used to enhance or alter images by converting one image into another while maintaining certain desired characteristics. The video uses this tool to upscale an image, which involves increasing its resolution while possibly introducing new details or correcting imperfections.

๐Ÿ’กDPM++ SDE Keras

DPM++ SDE Keras likely refers to a specific configuration or model used in AI image processing, involving Differential Privacy Mechanism (DPM), Stochastic Differential Equations (SDE), and Keras, a deep learning API. This setup is used to render images in the video, indicating a focus on achieving high-quality output through advanced AI techniques.

๐Ÿ’กDenoise Strength

Denoise strength in image processing adjusts the intensity of noise reduction techniques applied to an image. In the video, a denoise strength of 0.25 is used during the upscaling process to refine the image quality without overly smoothing out important details, thus allowing some flexibility for the AI to introduce new details.

๐Ÿ’กSharpen Unsharpen Mask

Sharpen Unsharpen Mask is a digital image processing technique used to enhance the visibility of edges and fine details in images. In the video, this method is employed after upscaling to improve the clarity and texture of the image, making elements like clothing and facial features more distinct.

๐Ÿ’กPNG

PNG (Portable Network Graphics) is a file format used for storing digital images. The video recommends saving images as PNG to avoid compression artifacts like those found in JPEG files, ensuring that the quality of the sharpened and upscaled images remains high.

๐Ÿ’กFace Restore

Face Restore is a technique used in AI image processing to enhance and correct facial features in images. The video suggests disabling Face Restore after certain steps to prevent blurring and maintain the sharpness and clarity achieved through previous processing steps.

๐Ÿ’กAutomatic 1111

Automatic 1111 appears to be the name of a software or tool used for AI image processing discussed in the video. It incorporates techniques like negative embeddings and upscaling to improve image quality. The video demonstrates how to manipulate and optimize images using this specific tool.

Highlights

Negative embeddings can be used to improve AI renders by training on undesirable image characteristics.

Embeddings are applied through the negative prompt to enhance the quality of the final image.

The negative prompt includes terms such as 'bad artist', 'bad prompt version', and 'bad hands'.

Embeddings are downloaded into the Automatic1111 folder and used by their name in the negative prompt.

Weights can be applied to embeddings, with 0.8 being a common value for effective results.

Different negative embeddings can significantly alter the image while still improving its quality.

Upscaling images can be enhanced by using image-to-image upscaling techniques.

Doubling the resolution and using DPM++ SDE Keras for rendering can improve image quality.

Denoise strength can be adjusted to allow for new details to be introduced by the AI.

Photo editing software like Affinity Photo or Photoshop can be used to sharpen the upscaled image.

Applying a 1-pixel unsharpen mask with 0% can enhance texture and details in the image.

Saving the sharpened image as a PNG avoids JPEG artifacts.

Face restore can be turned off after initial optimization to prevent blurring.

Comparing the original and new versions shows clearer details in the sharpened image.

Over-sharpening can cause issues like bright edges, which can be corrected by erasing the affected areas.

Adjusting the sharpening degree can prevent over-sharpening and maintain image quality.

The video provides a step-by-step guide on how to achieve high-quality AI renders through negative embeddings and upscaling techniques.

Viewers are encouraged to leave a like if they found the video helpful.