BEGINNER’S TUTORIAL SERIES
Easy mode with Brew

Positive/Negative prompts

AI upscale your images

Fine-tune with Render

> Upload/edit images [advanced]

Change visual styles

Make realistic AI characters

Has this ever happened to you?

stable diffusion error how to fix

nope, this isn’t normal. but it’s a common issue and an easy fix

Why this happens

When garbled faces appear, it either means (1) the AI model doesn’t have enough information on the topic (2)  it found the prompt confusing or (3) needs lower guidance or (4) all of the above. Luckily, it’s a quick fix.

Now’s a good time to teach you Guidance. It’s a hidden parameter of /brew and /render, and it has a number range from -50 to 50. A typical range is 6-10. Guidance tells the AI how much freedom is has to follow your instructions.  So the quick fix is to make sure our prompt is as clean as possible to understand, and to lower guidance.  Use this template:

The visual model also matters. Concepts like Real vision 1.3, Deliberate, Hassansblend, Analog and some others are great at celebrities from past years. If someone is recently famous, you’re better off uploading a photo of them and using a strong remix prompt if the AI models have no idea who they are yet.

Trouble prompt:

/render /size:800×600 full body shot of (Kate Bush 21 years old) wearing a wet blue (sku-mizu) swimsuit, doe eyes, studio lighting, (crouching on a bed) <realvis3>

This says it MUST be a 21 year old photo of Kate. Let’s decouple that. We can emphasize the person and be more flexible on other aspects, and lower the guidance, so it has more wiggle room to create the image.

Solution:

/render /portrait /guidance:4 full body photograph of ((Kate Bush)) young 21 years old wearing a wet blue (sku-mizu) swimsuit, doe eyes, studio lighting, (crouching, on a bed, bedroom scene, indoors) <realvis13>

Tada! She’s perfect. Then use /facelift to AI upscale the pixels 4x

Advanced Stable Diffusion tutorial: Resorting to a manual override with /guidance and /strength

When you issue a /render or /remix command, PirateDiffusion sets a number of silent parameters quietly in the background to give you a variety of creative results.

But before you dive into this parameters, I’d like to stress that using Guidance and Strength should be your last resort. Positive and negative prompts were invented after guidance and strength, so it’s possible to work without them. You only want to slide the volume up on Guidance when you want more embellish from the AI model, or toning it down when blue artifacts appear. These days, you might only see things like “CFG:7” in prompt examples and a whole lot of negative and positive prompts. That value refers to Classifier-free Guidance, or just Guidance or CFG for short.

This is insanely difficult to explain without a visual, so without further ado, here’s a visual of sliding up the Guidance by 0.1 every second:

Above: The same text prompt, but guidance goes up by 0.1 per second

Introduction to Guidance

The question of “how different should the variations be?” are determined hidden parameter called Guidance. Guidance is a number between -50 and 50, where 50 is “very creative” and around 4 is “safe”. By default, we set a random parameter between 4-10 in the background for you.

Think of guidance as a volume meter of how much freedom and creativity to allow in the original prompt. For wildly different results, increase the threshold. The lower you go, more straight forward the image should be.

/more /guidance:20

How to remember Guidance

Think about guiding a blind AI through the human world. You are literally guiding it through our language, pop culture, idioms, and so on, weaving to the far left is -50 (no guidance) and the far right is 50 (very guided).

Guidance is a range from -50 to 50

Four is considered a safe default.  Pirate Diffusion typically assigns a guidance value in the range of 8 to 20, but on some concepts as low as 4.

EXAMPLE

Guidance must go directly after /render in an order like this:

/render /guidance:4 a cool cat <inkpunk>

Higher guidance values can get you more specific results, but may worsen the stability and creativity of the image. Force too much guidance and you’ll get fuzzy squares and blocks. It depends greatly on the model.

Strength is for remixing images

/strength controls how much the images can vary when using Remix. So imagine you have two knobs on a mixer. Your original prompt is set by Guidance. The idea you’re introducing after a /remix has a slider called Strength. Why the makers of Stable Diffusion didn’t make them both have the same meter scale makes me want to scream into the void!  Where guidance is a -50 to 50 range, this one is different:

Strength is a number from 0.1 to 1.0

 

Now consider the graphic below carefully.  This is an example of how to tune a /remix. We are not adding both guidance and strength to a render to control two different creativity knobs at random on the onset.  The first image was created using /render barbed wire

Guidance answers the question: “How crazy are we going on /render?”

Strength answers the question: “How much /remix weight am I overriding?”

Top row: 

/render /guidance:X  barbed wire    … /remix /guidance:X cotton candy

Bottom row:

/render /guidance:5 barbed wire … /remix /strength:X cotton candy

If you think about it that way, it (almost!) makes more sense. You’re stacking strength on top of guidance when doing /remix. If you sort of got the idea, great. You’ll really get it when you get back to the editor and start experimenting on your own. There’s no better way to get this than doing.

Troubleshooting: Guidance is the best way to reduce artifacts

You may sometimes come across a pixelated output, such as blue artifacts, also known within our community as “squiggles” or “the terminator”. This means the render has failed in some way. This bug looks like this:

If you watched the video above, you’ll remember that too much guidance will fly a photo like this.  Too many prompts will also cause this when guidance is set too high. The good news is, this is a very easy thing to resolve.

This isn’t a censored image, it just means the guidance was set too high or the AI model is not understanding the tags.  Lower the guidance and choose a different model to make this go away immediately.

A parting thought: best practices before guidance and strength

Make sure you nail the best practices of a stable diffusion prompt first: express your idea very literally, organize the most important words towards the front of the prompt, use positive prompts, use negative prompts, and THEN let’s think about tossing in these parameters.

Sources:

PirateDiffusion is a Telegram implementation of Graydient AI Platform

BEGINNER’S TUTORIAL SERIES
Easy mode with Brew

Positive/Negative prompts

AI upscale your images

Fine-tune with Render

> Upload/edit images [advanced]

Change visual styles

Make realistic AI characters

/brew a celestial laser eye, by Alex

pirate diffusion logo

Render-Ahoy!