File size: 3,607 Bytes
f97c473
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
import gradio as gr
import random

# Define the function to generate multiple prompts
def generate_all_prompts(name):
    # List of clothing combinations with colors and types of miniskirts
    outfits = [
        "a form-fitting elastic cotton miniskirt and a tight short dress in red",
        "a tight short dress and a form-fitting elastic cotton miniskirt in black",
        "a leather miniskirt and a crop top in blue",
        "a denim miniskirt and a tank top in white",
        "a pleated miniskirt and a blouse in green",
        "a bodycon miniskirt and a bandeau top in pink",
        "a metallic miniskirt and a camisole in silver",
        "a lace miniskirt and a bustier in gold",
        "a PVC miniskirt and a mesh top in purple"
    ]

    # List of camera angles
    angles = [
        "low angle shot looking up",
        "worm's eye view",
        "dynamic low angle"
    ]

    # List of leg positions
    leg_positions = [
        "legs crossed",
        "one leg bent",
        "standing with legs slightly apart",
        "sitting with legs to the side",
        "kneeling"
    ]

    prompts = []
    for _ in range(3): # Generate 3 distinct prompts
        # Randomly select one outfit, angle, and leg position
        selected_outfit = random.choice(outfits)
        selected_angle = random.choice(angles)
        selected_leg_position = random.choice(leg_positions)

        # Create the single prompt with the randomly selected outfit, angle, leg position and added details
        prompt = f"/imagine a photorealistic full body portrait of {name}, occupying the entire frame, extreme close-up full body shot, posing sensually and confidently, wearing {selected_outfit} with a subtly more transparent texture, high heels, elegant hairstyle with long hair, captured with a high-end DSLR camera, bright midday sun, full frame, no annoying shadows or borders, perfect lighting, park setting, high-resolution, 8k, cinematic photography, sharp focus, vibrant colors, {selected_angle}, {selected_leg_position}."
        prompts.append(prompt)

    # Return the list of prompts
    return prompts

# Define the CSS theme
css_theme = """
.gradio-container {
    background-color: #1a1a1a;
    color: #ffffff;
}
.dark .gradio-container,
:root .dark .gradio-container {
    background-color: #1a1a1a;
    color: #ffffff;
}
.gradio-button {
    background-color: #dc2626;
    color: #ffffff;
    border-radius: 8px;
    border: none;
    font-weight: bold;
}
.gradio-button:hover {
    background-color: #ef4444;
}
.gradio-textbox textarea, .gradio-textbox input {
    background-color: #262626;
    color: #ffffff;
    border: 1px solid #4a4a4a;
}
.gradio-label {
    font-weight: bold;
    color: #ffffff;
}
h1 {
    color: #ef4444 !important;
    text-align: center;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    text-shadow: 2px 2px 4px #000000;
}
"""

# Gradio UI setup
with gr.Blocks(
    title="🐾BATUTO_-1",
    css=css_theme
) as demo:
    gr.Markdown(
        """
        # 🐾BATUTO_-1 🤖✨
        """
    )
    with gr.Row():
        name_input = gr.Textbox(label="Enter the celebrity's name", scale=3)
        generate_btn = gr.Button("Generate Prompt", scale=1)

    # The UI now has only one output box
    with gr.Column():
        prompt_output = gr.Textbox(label="Generated Prompt:", lines=5, interactive=False, show_copy_button=True)

    # Link the button to the function
    generate_btn.click(
        fn=generate_all_prompts,
        inputs=name_input,
        outputs=prompt_output
    )

if __name__ == "__main__":
    demo.launch()