AI 이미지/Stable Diffusion

멋진 이미지를 생성하는 SDXL 프롬프트 15개

하늘이푸른오늘 2023. 7. 30. 00:18

SDXL - a photo of large fish tank, japanese style
SDXL - a photo of large fish tank, japanese style

SDXL은 최신 Stable Diffusion 기술입니다. SD 1.5/2.1에 비해 생성되는 이미지의 품질이 매우 높아졌습니다. SDXL은 언어모델이 다르기 때문에 스테이블 디퓨전 v1에서 사용되는 프롬프트와는 약간 다릅니다.

이 글에서는 여러가지 스타일의 SDXL 프롬프트와, 그 결과로 생성된 이미지를 보여드립니다. 이를 기본으로 해서 여러가지 테스트를 해보시거나, 필요하신 새로운 프롬프트를 개발하실 수 있을 것입니다.

소프트웨어 설치

SDXL은 Stable Diffusion을 설치한 후 여기에 SDXL 모델을 탑재하여 사용하는 방법과, Stable Diffusion를 개발한 Stability AI에서 제공한 테스트 사이트인 Clipdrop에서 사용하는 방법이 있습니다. 물론 검색해 보시면 여기에서 언급하지 않은 여러가지 방법이 존재합니다만, 저는 제가 편하다고 생각하는 방법만 정리한 것이니 참고하시기 바랍니다. 이 글에서는 AUTOMATIC1111에 SDXL 모델을 사용하여 이미질를 생성합니다.

SDXL 프롬프트 테스트 환경

모든 이미지는 SDXL 1.0 을 사용하여 생성합니다. SDXL은 base 모델과 refiner 모델, 2단계로 구성됩니다. 먼저 base 모델로 이미지를 생성하고, 생성된 결과물을 refiner 모델로 돌리면 세부적인 디테일이 추가되는 방식입니다. 그런데, 저는 base 모델만 사용해 이미지를 생성하는 것을 원칙으로 합니다. 2 단계를 모두 사용하려면, 모델을 교체해야 하는데 모델을 읽어들이는 시간이 꽤 걸리기 때문입니다(3060을 쓰는데 거의 4-5분 정도 소요됩니다). base 모델로 생성된 결과가 별로 안좋다고 느껴질 때에만 refiner 모델을 사용할 것이며, refiner 를 사용했다는 사실을 밝히도록 하겠습니다.

아래는 생성 파라미터입니다.

  • 이미지 사이즈 : 1152x896 (필요에 따라 가로 세로를 바꿀 수 있습니다)
  • 샘플링 방법 : Euler a
  • base 모델 샘플링 단계: 20
  • refiner 모델 샘플링 단계: 10
  • refiner 모델 잡음제거 강도: 0.2

또한, 이 글은 원본 글에 있는 프롬프트를 그대로 사용해서 이미지를 생성하고, 생성된 이미지를 보면서 제 머리속에 떠오른 내용을 ChatGPT를 사용하여 프롬프트로 생성하고, 이를 이용해 이미지를 생성하는 2단계로 작업했음을 알려드립니다. 

1.  바에서 술을 마시는 코뿔소

프롬프트: photo of a rhino dressed suit and tie sitting at a table in a bar with a bar stools, award winning photography, Elke vogelsang
부정적 프롬프트: cartoon, illustration, animation. face. male, female

이 프롬프트는 매우 잘 먹힙니다. 4개를 생성했는데, 모두 아주 잘 표현하고 있습니다.

그래서 좀 다른 걸 시도해 봤습니다. 클럽에서 춤을 추고 있는 치타입니다. 

프롬프트: A cheetah dancing at the club, the cheetah has young woman's body, dressed in tight-fitting clothes and a short skirt. The sleek and stylish outfit accentuates its agile and graceful movements, making the cheetah the center of attention on the dance floor, exuding confidence and charm with every step.
부정적 프롬프트: cartoon, illustration, animation. face. male

이 프롬프트는 ChatGPT로 생성했습니다. 그런데 별로 잘 먹지 않아서 진짜 치타가 나오거나, 치타 장식이 추가된 여성이 나오는 경우가 많았습니다. 특히 배경으로 사람을 넣으니 아예 여성으로만 생성되서 포기했습니다.

2. 숲속의 몬스터

프롬프트: a giant monster hybrid of dragon and spider, in dark dense foggy forest
부정적 프롬프트: catoon

오! 멋지네요. 정말 몬스터가 잘 표현되었습니다. 이 프롬프트도 잘먹히네요. 4장 모두 성공했습니다.

이 이미지를 보니 반지의 제왕 골룸이 생각나서 프롬프트를 만들어봤습니다. 물론 ChatGPT를 사용해 생성했습니다. "깊은 숲속 작은 개울 옆에 웅크리고 앉아, 두려워하며 어딘가를 응시하고 있는 골룸" 입니다.

프롬프트: realistic photo of a Gollum, crouched by a small stream in the heart of a deep forest, appears anxious and fearful as he gazes into the distance, his eyes filled with trepidation. His hunched figure and twitching movements reveal the inner turmoil of the tormented character, hinting at the shadows of his past and the uncertainties of his future.
부정적 프롬프트: cartoon

이 프롬프트도 아주 잘 먹힙니다. 그런데 원래는 "거미와 골룸의 하이브리드가 사슴을 잡아먹는 모습"으로 시작했는데 도저히 표현이 안되어서 4-5번 고쳐서 이 프롬프트가 되었습니다.

3. 비눗방울이 놀라워!

프롬프트: a little boy with ginger hair wearing denim overalls chasing bubbles. clean pastel painting, beautiful detailed face, lots of bubbles, photorealistic 

정말 잘 생성됩니다. 그리고 SD와는 다르게 생성되는 인물이 거의 비슷하게 나옵니다. 원래의 글에서는 가로로 생성했고 저는 세로로 생성했는데도 불구하고 같은 프롬프트를 사용하면 (자세는 달라도) 비슷한 얼굴이 생성되는 게 아주 신기합니다.

그러면 저는.... 풀장에서 물놀이를 하는 여자 아이를 그려볼까요? "풀장에서 즐겁게 물놀이 하는 여자아이. 부모가 흐뭇한 표정으로 지켜보고 있다" 를 프롬프트로 생성했습니다. chatGPT에게 요청하면 아래와 같이 아주 길게 나옵니다.

프롬프트: A young girl joyfully playing in the pool, her laughter echoing through the air as she splashes and swims with excitement. Her parents stand nearby, wearing proud and content expressions, as they watch their daughter gleefully embrace the simple pleasures of water play. The scene radiates warmth and happiness, capturing the cherished moments of family bonding and childhood innocence. 

A young girl joyfully playing in the pool
A young girl joyfully playing in the pool
A young girl joyfully playing in the pool
A young girl joyfully playing in the pool

여자아이는 아주 잘 그려졌습니다. 그런데 세로 그림을 가로로 바꿨는데도 "흐뭇한 표정의 부모"는 나타나지 않네요. 생성해보면서 느끼는데, 주 피사체를 여럿 지정하면 잘 표현하지 못하는 것 같습니다. 프롬프트를 "엄마와 함께 물놀이하는 여자아이"로 고치니까 나아지긴 하는데 좀 더 테스트 해보는 게 좋을 것 같습니다. 다음에 구역분할 프롬프트를 사용하면 해결되는지 시험해 봐야겠습니다.

4. 꽃속의 여인

프롬프트 : beautiful woman wearing fantastic hand-dyed cotton clothes, embellished beaded feather decorative fringe knots, colorful pigtail , subtropical flowers and plants, symmetrical face, intricate, elegant, highly detailed, 8k, digital painting,trending on pinterest, harper’s bazaar, concept, art, sharp focus, illustration, Tom Bagshaw, Lawrence Alma-Tadema, Alphonse Mucha 

아주 환상적인 여인의 모습이 생성되었습니다. 이 프롬프트를 사용하면 거의 오류가 나지 않네요.  Tom Bagshaw, Lawrence Alma-Tadema, Alphonse Mucha 등 3명의 아티스트를 섞어 생성하도록 지시했는데, 제가 보기에는 알폰스 무하의 느낌이 매우 강합니다. 특유의 동그란 프레임은 나타나지 않지만요. 알폰스 무하의 스타일이 워낙 강렬하기 때문인 것 같습니다.

"유럽 농가 풍경이 보이는 창가에서 책읽는 소녀"입니다. 르누아르와 요하네스 베르레르 풍으로 그려달라고 했습니다.

프롬프트: painting of a girl reading a book by the window, with a picturesque European countryside landscape in view. The soft rays of sunlight gently illuminate the cozy scene as the girl engrosses herself in the pages of her book, immersing herself in the captivating world of literature amidst the serene beauty of the rural countryside. by Johannes Vermeer and Pierre-Auguste Renoir

보시는 것처럼 잘 그려냅니다. 다만, 두 화가의 스타일이 달라서, 특히 인상파인 르누아르 화풍이 강해서 베르메르 스타일은 거의 나타나지 않는 것 같네요.

5. 검은색 갑옷을 착용한 여전사

프롬프트: a woman with black armored uniform, futuristic, giant robot, inspired by Krenz Cushart, neoism, kawacy, wlop, gits anime 

멋지니다. 정말 어느 애니 작품 콘셉트 이미지라고 해도 손색이 없을 정도네요. 이러니 작가들이 힘들어 할 수 밖에요. 앞으로는 더 심해질 것 같고... 걱정이 많이 됩니다.

한글 프롬프트: "컬러풀한 갑옷을 입고 큰 칼을 가진 여전사가 건담의 어깨에 타고 있음"
프롬프트: A colorful-armored female warrior, wielding a large sword, rides atop the shoulder of a Gundam. Her vibrant armor, adorned with a myriad of hues, stands out in the midst of the futuristic battlefield. With her mighty weapon in hand, she commands the towering robot with grace and skill, becoming an awe-inspiring force to be reckoned with.

건담의 어깨에 타고 있는 모습으로 그려달라고 여러번 시도를 했는데 결국 실패를 했습니다. 건담스타일의 여전사가 되어버렸네요. 건담 자체가 강력한 키워드인 듯 합니다. 아래는 위의 오른쪽만 refiner를 돌려본 결과입니다. 전체적인 형상은 그대로 유지되었지만, 얼굴이 많이 달라졌고, 면의 질감이 달라졌습니다. 그러나 어느쪽이 더 좋다고 주장하기에는 좀 애매한듯 합니다.

컬러풀한 갑옷을 입고 큰 칼을 가진 여전사
컬러풀한 갑옷을 입고 큰 칼을 가진 여전사

6. 지하철을 기다리는 남자

프롬프트: b&w photography, model shot, man in subway station, beautiful detailed eyes, professional award winning portrait photography, Zeiss 150mm f/2.8, highly detailed glossy eyes, high detailed skin, skin pores 

멋집니다. 작품사진처럼 느껴진네요. 프롬프트 자체도 괜찮아서 거의 오류가 없습니다. 

위의 이미지를 보니 흑백영화가 생각이 나서 프롬프트를 만들어 봤습니다. 2차 세계대전과 흑백 영화. ㅎㅎ

한글 프롬프트: 2차 세계대전 중 참호에서 총을 겨누고 있는 베테랑 군인의 흑백사진
프롬프트: A black and white photograph capturing a veteran soldier aiming his gun from a trench during World War II. The intensity in his eyes and the determined grip on the weapon speak volumes about the courage and resilience of those who served on the frontlines during one of history's most significant conflicts. The powerful image serves as a poignant reminder of the sacrifices made by the brave men and women during the war.

노병의 결기가 느껴집니다. 정말 종군 기자가 촬영했을 것 같은 느낌이네요. 프롬프트 자체도 아주 좋습니다. 계속 반복해도 오류가 거의 없네요. 

7. 총을 든 여전사

프롬프트 : a woman in a futuristic suit holding a gun in her hand, looking at the camera, cyberpunk art, neo-figurative, anime 

우와! 황홀하네요. 사이버펑크 스타일~~~ 정말 제 취향입니다.

아... 이걸보니 하울의 움직이는 성 분위기의 스팀펑크 스타일이 땡기네요. (그냥 단어만 비슷한 겁니다. 압니다.ㅠㅠ) 

한글 프롬프트: 꽃이 피고 나무가 드문 드문 있는 평원위로 날라가는 스팀펑크 스타일의 전함.
프롬프트: A steampunk-style airship soaring over a plain adorned with blooming flowers and sparse trees. The vessel's intricate design and vintage machinery evoke a sense of wonder and nostalgia. As it gracefully takes flight, billowing steam and gears in motion add to the mesmerizing spectacle of the airborne marvel. The scene portrays a unique blend of nature's beauty and the ingenuity of steampunk technology, creating a captivating and enchanting visual

우왕! 멋지네요. 예전에 SD 1.5 로 이 분위기를 표현하고 싶어서 여러번 시도하다가 결국 포기한 적이 있어서 더 감격스럽습니다. 멀리 유럽 고성과 구리빛 비행전함이 너무 잘 어울립니다. SDXL을 사용할 수 있다면 이 프롬프트는 한번 시도해 보세요. 실패란 없습니다~ ㅎㅎ

8. 돌 쌓기

프롬프트 : a beautiful stack of rocks sitting on top of a beach, a picture, red black white golden colors, chakras, packshot, stock photo 

멋지네요. 실제로는 저렇게 자갈을 쌓아올릴 수 없겠지만, 자갈들이 살아있는 듯 합니다. 그런데, 모든 사진이 아웃포커스로 나오는데... 실제로 사진을 촬영하면 아웃포커스 되는 게 맞긴 하겠는데, 인공지능 이미지가 이렇게 나오니 기분이 묘하네요.

돌 쌓는 걸 보니... 뭐니뭐니 해도 쌓기에는 레고겠죠? 그래서 한번 프롬프트를 짜봤습니다. 

한글 프롬프트: 레고 브릭이 흩어진 가운데, 주로 회색 브릭으로 만든 레고 성이 서있는 모습. 아이들이 즐겁게 쳐다본다.
프롬프트: In the midst of scattered Lego bricks, a Lego castle from Lego castle series stands, built from mainly gray Lego pieces. Boys and girls watching in amusment. The impressive structure showcases the creativity and ingenuity of its builder, who skillfully transformed the random assortment of bricks into a captivating architectural feat.

여러번 시행착오를 했습니다. 저는 아이들이 가지고 노는 작은 성을 생각했는데, 엄청 규모가 큰 성을 생성하네요. 그리고 아이들을 함께 그리라고 했더니 잘 구성하질 못합니다. 주 피사체가 여러개가 되면 문제가 있는 것 같네요. 좀더 연구해 봐야겠습니다.

9. 노란 나비

프롬프트: a painting of a woman with a butterfly on a yellow wall, hip skirt wings, graffiti art, inspired by Brad Kunkle, Tutu, Russ Mills, Andrey Gordeev

예술적인 그림도 척척 그려냅니다. 정말 분위기를 잘 살려내는 프롬프트네요.

뭔가... 이런 프롬프트를 활용해서 새로운 것을 그려보려는데 잘 떠오르지를 않네요. 그래도 한번...

한글 프롬프트. 바닥에 주저 앉아서 두 무릎을 팔로 감싸고 머리를 숙이고 있는 긴머리 여성의 그림. 무언가 깊은 고민을 하는 듯한 옆모습
프롬프트: In a beautifully drawn illustration, a long-haired woman sits on the floor, her knees pulled close to her chest, and her arms wrapped around them. Her head is bowed down, and her deep contemplative expression suggests that she is lost in profound thought. The intricate details and emotion captured in the artwork convey a sense of inner turmoil and introspection, inviting viewers to ponder the complexity of her thoughts and emotions.

무릎을 끌어 안고있는 모습을 그리는 게 힘드네요. 아마도 서양인들에게 그런 자세가 쉽지 않아서 그렇지 않을까 싶습니다. 

10. 전사

프롬프트: a woman with long blonde hair sitting on the ground, cyberpunk art, by Krenz Cushart, wears a suit of power armor, closeup character portrait, cute detailed digital art, artgerm and Lois van Baarle, japanese anime, 1girl

아마도 원본 글을 작성하시는 분은 이런쪽의 작업을 하시는 분 같습니다. 윗쪽부터 프롬프트를 잘 살펴보면 예술가의 이름이 반드시라고 해도 될 만큼 자주 사용되고 있거든요. 아마 이런 예술가의 이름을 넣어주면 훨씬 그림체가 분명해지고, 생성되는 이미지도 좀더 멋져지는 게 아닐까 싶네요.

그런데, 저도 이미지를 생성하면 꼭 여성을 그리게 되네요. 뭐... 이해해주시리라 믿지만, 이번엔 강한 남성 전사를 그려보겠습니다.

한글 프롬프트: 최소한의 갑옷만 걸치고 있는 근육질 전사. 도끼를 어깨에 걸치고 전투 준비를 하고 있음. 멀리서 전투가 벌어지고 마법사들이 여러가지 마법을 날리고 있음
프롬프트: In a stunning artwork, a muscular warrior stands, wearing minimal armor, with an axe slung over his shoulder. He exudes a formidable presence, preparing for battle with a determined expression on his face. In the distance, epic combat unfolds as various wizards unleash powerful spells, filling the battlefield with mesmerizing bursts of magic. The illustration captures the essence of an intense and fantastical battle scene, where bravery and magic collide in a breathtaking display of action and heroism.

전체적으로 생각한 대로 묘사가 된 듯한데, 전투용 도끼는 표현이 잘 안되네요. 그래도 극적인 분위기는 잘 표현되었습니다.

11. 물고기

프롬프트: a painting of a fish on a black background, a digital painting, by Jason Benjamin, shutterstock, colorful vector illustration, mixed media style illustration, epic full color illustration, mascot illustration

여기에도 아티스트의 이름(Jason Benjamin)이 들어 있습니다. 그래서 검색을 해봤는데, 별로 이런 스타일의 그림을 그린 분은 아닌듯 했습니다. 그래서 이름을 빼고 생성시켰더니 약간 분위기는 달라졌지만 대체로 비슷한 스타일을 유지하네요. 이 그림에서는 아티스트의 이름이 영향이 별로 많지 않나봅니다. 어쨌든 이 프롬프트를 사용하면 이런 스타일의 물고기를 양산 시킬 수 있겠네요.^^

생각난 김에 수족관을 그려보겠습니다. 예전에 SD1.5로 시도를 해봤었는데 그때는 별로 수초들이 마음에 안들었었거든요.

프롬프트: a photo of large fish tank, japanese style, Yamano, meticulously arranged rocks, captivating driftwoods, lush freshwater aquatic plants, hairgrass, anubius nana, foreground watergrass, black sand, diverse species of tropical freshwater fish, guppies, platties neon tetras, graceful movements, beauty, tranquility, soft ambient lighting, shimmering reflections, gentle underwater rays of light
부정적 프롬프트: monotone, boring, watermark, text, overexposed, simple, minimalist 

아래는 예전에 그린 이미지중에서 그나마 제일 잘 뽑힌겁니다. 

SD 1,5 - a photo of large fish tank, japanese style
SD 1,5 - a photo of large fish tank, japanese style

아래는 SDXL로 생성한 이미지입니다. 참고로 아래 이미지는 1536 x 640 크기로 생성했습니다. 

SDXL - a photo of large fish tank, japanese style
SDXL - a photo of large fish tank, japanese style
SDXL - a photo of large fish tank, japanese style
SDXL - a photo of large fish tank, japanese style

어항사진도 일본 스타일 세팅으로 잘 표현해 주네요. 수초어항 세팅은 크게 일본식과 네덜란드식으로 나눠지는데, 예전의 울긋불긋하고 큰 수초들이 많은 어항은 네덜란드식에 가깝고, 아래와 같이 작은 수초들로 자연을 닮은 형태로 꾸미는 게 일본식입니다. 아무튼.. 어항도 잘 그려주니 기분이 좋네요.

12. 어두운 거리를 걷는 여인

프롬프트: a woman in a pink dress walking down a street, cyberpunk art, inspired by Victor Mosquera, conceptual art, style of Raymond Wwanland, Yume Nikki, restrained, robot girl, ghost in the shell 

원본 글 저자분은 사이버펑크 스타일을 좋아하시나 보네요. 윗쪽에도 사이버펑크 스타일의 여전사가 있는데 또 다시 등장시킨 걸로 봐써요. 핑크색 옷의 연인과 사이버펑크 아트 스타일이 잘 어울리는 듯 합니다.

흠... 이소룡 님이 생각났습니다. 노란색 추리닝 ㅎㅎ

한글 프롬프트: 사망유희에 나오는 노란색 추리닝을 입고 쌍절곤을 든 이소룡
프롬프트: In the iconic movie "Game of Death," Bruce Lee appears dressed in his distinctive yellow tracksuit, holding nunchucks in his hands. With his lightning-fast movements and masterful control of the nunchucks, he mesmerizes audiences with his extraordinary martial arts skills. The image of Bruce Lee in his yellow tracksuit, wielding the nunchucks, has become an enduring symbol of his legacy as a martial arts legend and cultural icon. 

쌍절곤은 없지만, 이소룡은 살아있네요. ㅎㅎ

13. 음악은 어디에나

프롬프트: a man in a space suit playing a guitar, inspired by Cyril Rolando, shutterstock, highly detailed illustration, full color illustration, very detailed illustration, Dan Mumford and Alex Grey style 

우주에서는 움악을 들을 수 없습니다. 음파가 퍼져나갈 매질(공기 등)이 없기 때문이죠. 그렇다고 기타를 못치는 건 아니죠. 우주복이 제 생각과는 좀 다르기는 하지만, 잘 표현이 되었고, 오류도 없습니다. 좋네요.

우주를 생각하면 당연히 스타워즈죠. 여전히 ChatGPT를 사용해서 프롬프트를 만들었는데, 너무 길어서 짧게 하라고 했더니 딱 번역만 했네요. ㅎㅎ

한글 프롬프트: 행성을 파괴하기 위해 준비중인 데스 스타. 스타 디스트로이어가 접근하고 있다
프롬프트: The Death Star prepares to destroy a planet, as a Star Destroyer approaches.

여러번 생성시켰는데, 오히려 프롬프트를 짧게 했을 때가 더 원하는 장면을 잘 생성하는 것 같네요. SDXL의 언어모델 성능이 대단하다는 걸 새삼 느꼈습니다.

14. 수묵화

프롬프트: a painting of a beautiful graceful woman with long hair, a fine art painting, by Qiu Ying, no gradients, flowing sakura silk, beautiful oil painting

수묵화 스타일, 특히 Qiu Ying 작품 스타일이라고 했지만, 동양인으로서는 이런 그림이 수묵화 스타일이라고 하기는 힘들죠. 

한글 프롬프트: 산과 큰 호수가 있는 중국 전통 수묵화, 선비가 다리를 건너 호수 속 섬에 있는 작은 모옥을 방문하러 가는 중이다
프롬프트: In a traditional Chinese ink wash painting, depicting mountains and a large lake, a scholar is seen crossing a bridge on his way to visit a small thatched cottage on an island in the lake. The serene scene captures the tranquility of nature and the scholar's contemplative journey, evoking a sense of peaceful harmony between man and the natural world. 

이렇게 하니 정말 산수화 같네요 모옥(초가집)을 표현하지 못한게 아쉽기는 하지만, 분위기는 잘 살렸네요. 이러고 보면, 정말 SDXL base 모델에 얼마나 많은 이미지를 갈아넣었을지... 새삼 무서워지네요.

15. 곱슬머리 모델

프롬프트: model shot of a woman with long curly highlight hair posing for a picture, rendered in lumion pro, anime girl in real life, beautiful portrait photo, bright background
부정적 프롬프트: ugly, deformed

오... 정말 멋지네요. 이런 분을 현실에서 만나면 숨이 넘어갈듯요. ㅎㅎ

한글 프롬프트: 빨간머리 앤이 친구들과 함께 캐나다 로키를 배경으로 초원에서 달리고 있다
프롬프트: In the vast Canadian Rockies, amidst the breathtaking scenery of the prairies, Anne with her friends gallops on horseback. The wind tousles their red hair as they race through the open meadows, their laughter echoing through the wilderness. The stunning landscape provides the perfect backdrop for their exhilarating adventure, capturing the joy and freedom of their journey in the heart of nature's beauty.

아... 저 이렇게 말타고 달리고 싶어요. 우리에서 뱅뱅 도는 거 말고요. 정말 부럽네요(사실은 말도 못탑니다 ㅠㅠ). 정말 멋지네요. 정말 SDXL로 이미지를 생성하면 너무 기분이 좋네요~

민, 푸른하늘