【Stable Diffusion】背景を上手く生成させるためのコツと呪文集をまとめて紹介

AIジェネ【AIイラスト生成の情報発信】
18 Aug 202309:11

TLDRThe video provides a comprehensive guide on generating high-quality backgrounds using the 'anylora' and 'anythingV5' models from the Civitai model distribution site. It emphasizes the use of specific prompts and negative prompts to generate backgrounds without characters or people. The video suggests adding 'background only:2' to prompts and using negative prompts like 'character, person, human, people' to omit people from the generated images. It also recommends using 'masterpiece, best quality, detailed background' to enhance image quality. The importance of image size and the use of 'hires.fix' for higher quality are highlighted. The video advises changing the sampling method if the desired style isn't achieved and encourages experimenting with different models to achieve the desired background. It also covers various background spells for specific settings like 'morning', 'day', 'evening', and 'sun', as well as indoor and outdoor scenarios. The summary concludes with the reminder that not all backgrounds can be generated with a single model and encourages trying different models and image sizes for the best results.

Takeaways

  • 🎨 Use specific models like 'anylora' and 'anythingV5' from Civitai for generating backgrounds.
  • 📝 Include 'background only:2' in your prompt to focus on generating only the background.
  • 🚫 Utilize negative prompts such as 'no character', 'no person' to avoid generating people in the background.
  • 🖼️ Enhance the quality of the background by using prompts like 'masterpiece', 'best quality', 'detailed background'.
  • 📏 Increase the image size to 1024 or more on one side, or use 'hires.fix' to improve the quality of the generated background.
  • 🔍 Experiment with different sampling methods to find the best one for your desired background style.
  • 🏞️ Recognize that not all backgrounds can be generated with a single model, and consider using multiple models.
  • 🌅 Add specific time-of-day or weather spells (e.g., 'morning', 'sea') to generate backgrounds with those conditions.
  • 🏡 For indoor settings, specify the type of room (e.g., 'japanese-style room') to get more accurate results.
  • 🌇 Use 'sun' or 'sun, sea' in combination with other spells to increase the chances of generating a background with the sun.
  • 🔄 If the desired background isn't generated well, try changing the image size as a troubleshooting step.

Q & A

  • What is the purpose of the video?

    -The video aims to introduce a collection of tricks and background spells for successfully generating backgrounds using 'anylora' and 'anythingV5' from the Civitai model distribution site.

  • Why might someone want to generate only the background in an image?

    -Some people might want to create an illustration collection with only the background or use it as material for game development.

  • How can one increase the variation of scenery in generated backgrounds?

    -By using different models, adjusting prompts, and experimenting with various background spells and negative prompts to omit elements like people.

  • What is a recommended prompt to generate a high-quality background?

    -Adding 'background only:2' in brackets to the prompt, along with negative prompts like 'no character', 'no person', 'no human', 'no people'.

  • How can one ensure the generated image has a detailed background?

    -By including the spell 'masterpiece, best quality, detailed background' in the prompt.

  • What is the relationship between image size and quality in generated images?

    -Larger image sizes, such as setting one side to 1024 pixels or more, or using 'hires.fix' to double the image size, generally result in better quality.

  • Why might changing the sampling method improve the background style?

    -Different models respond differently to sampling methods, and trying various methods can help find the one that best suits the desired style.

  • What should one do if they cannot generate a specific type of background?

    -If a particular background is difficult to generate, one can try using different checkpoint models or lora models, or changing the image size.

  • How can one generate an early morning background?

    -Adding the spell 'morning' to the prompt, and specifying additional details like 'sea' for a more accurate generation.

  • What is the advantage of using a combination of spells for generating the sun?

    -Combining 'sun' with another spell like 'sea' can make it easier for the model to generate the desired image.

  • What is the video's recommendation for generating indoor scenes like a Japanese-style room?

    -Entering specific terms like 'japanese-style room' into the prompt, potentially using a Japanese-style human model or background model for better results.

  • What is the final advice given in the video for generating backgrounds?

    -If a background image is not generated well, it may be possible to generate it by changing the image size or using multiple models that specialize in generating backgrounds.

Outlines

00:00

🎨 Background Creation Techniques

This paragraph discusses the desire to create only the background for various uses such as illustration collections or game development. It introduces the use of 'anylora' and 'anythingV5' from the Civitai model distribution site to generate high-quality backgrounds. The speaker explains the use of specific 'background only' prompts and negative prompts to exclude characters and focus solely on the scenery. They also highlight the importance of image size and sampling methods in achieving the desired style and quality. The paragraph emphasizes the limitations of models and suggests trying different ones if the desired background is not generated. It concludes with a teaser for various background spells that will be introduced later in the video.

05:08

🌅 Generating Specific Backgrounds

The second paragraph provides a summary of the video's content, focusing on the generation of backgrounds using different models. It acknowledges the limitations that one model may not be able to create all types of backgrounds and suggests using multiple models or a specialized model for better results. The speaker also advises on changing the image size if the desired background is not generated well. They mention that while the quality of generated images might be a bit blurry, it's possible to create beautiful images by using appropriate models. The paragraph ends with a call to action, encouraging viewers to subscribe to the channel for more content related to generated AI.

Mindmap

Keywords

💡Stable Diffusion

Stable Diffusion refers to a type of generative model used in machine learning to create images from textual descriptions. In the context of the video, it is the core technology that enables the creation of backgrounds without characters or people, which is the main theme of the video.

💡Background-only prompts

Background-only prompts are specific textual instructions given to a generative model to generate images that include only the background and exclude any characters or people. This is a key concept in the video as it discusses how to generate such backgrounds effectively.

💡Negative prompts

Negative prompts are phrases used to guide the generative model away from including certain elements in the generated image. For example, using 'no people' or 'no characters' as negative prompts helps in creating images with only the background, which is a central technique discussed in the video.

💡Image size

Image size refers to the dimensions of the generated image, which can affect the quality and detail of the background. The video suggests setting the image size to 1024 or more on one side to increase the quality of the background, which is crucial for high-resolution outputs.

💡Sampling method

The sampling method is a technique used by the generative model to decide how to generate each pixel of the image. Different models may have different sampling methods, and the video suggests trying various methods to find the one that best suits the desired background style.

💡Checkpoint models

Checkpoint models are specific versions or states of a generative model that have been saved at certain points during its training. The video mentions using different checkpoint models to achieve a wider variety of background styles, which is important for generating diverse backgrounds.

💡Lora models

Lora models, or LoRA (Low-Rank Adaptation), are a type of neural network architecture that allows for fine-tuning of specific parts of a model. In the video, they are mentioned as a way to specialize in generating only the background, which is a key strategy for achieving the video's goal.

💡Japanese-style room

A Japanese-style room refers to an interior design that follows traditional Japanese aesthetics. The video uses this as an example of a specific type of indoor background that can be generated using the discussed techniques, showcasing the versatility of the generative model.

💡Outdoor spells

Outdoor spells are specific prompts used to generate outdoor scenes as backgrounds. The video provides examples of such spells, like 'morning' and 'sea', to illustrate how to create detailed outdoor backgrounds, which is a significant part of the video's content.

💡Quality enhancement

Quality enhancement refers to the process of improving the visual quality of the generated background. The video discusses using larger image sizes and specific prompts like 'masterpiece' to achieve high-quality backgrounds, which is essential for creating professional-looking images.

💡Indoor spells

Indoor spells are prompts that guide the generative model to create indoor scenes as backgrounds. The video mentions 'japanese-style room' as an example of an indoor spell, emphasizing the importance of specific prompts in generating the desired type of background.

Highlights

A collection of tricks and background spells for successfully generating backgrounds using 'anylora' and 'anythingV5' from the Civitai model distribution site.

Background-only spells tend to include a lot of people, but can be adjusted with specific prompts and negative prompts.

Adding 'background only:2' in brackets to the prompt can help generate images with only the background.

Using negative prompts like 'no character', 'no person', 'no human', 'no people' can increase the number of images generated with only the background.

Different models may require different approaches to omit people from the generated backgrounds.

High-quality backgrounds can be generated by using the spell 'masterpiece, best quality, detailed background'.

Image quality can be improved by increasing the image size to 1024 or more on one side or using 'hires.fix'.

The sampling method can be changed to achieve the desired style of the background.

Not all backgrounds can be generated with a single model, and using multiple models or lora models may be necessary.

Natural backgrounds are easier to generate than certain indoor buildings.

The model's training determines whether a background can be generated or not.

Changing the image size can help generate the ideal image if the background is not coming out well.

Various background spells will be introduced for different settings like early morning, daytime, sunset, and specific themes.

For early morning backgrounds, add the spell 'morning'.

Specifying weather conditions, like 'morning, sea', can make it easier to create the desired background.

Setting the image size to 600 vertical or horizontal can help generate backgrounds according to the spell.

For daytime images, add the 'day' spell, and for sunsets, use the 'evening' spell.

Combining 'sun' with other background spells like 'sea' can make it easier to generate a sun in the image.

To generate an image of a Japanese-style room, enter 'japanese-style room'.

Outdoor backgrounds can be generated using specific spells tailored to the desired outdoor setting.

The video provides a summary of the methods to create only the background using different models and spells.

Ai Gene disseminates information about generated AI, and viewers are encouraged to subscribe for more content.