This commit is contained in:
lvmin 2023-08-10 19:15:22 -07:00
parent aa4396e670
commit ade641f0e7
2 changed files with 3 additions and 2 deletions

View File

@ -20,7 +20,8 @@ with block:
with gr.Column():
prompt = gr.Textbox(label="Prompt", value='a handsome man in forest')
run_button = gr.Button(label="Run")
result_gallery = gr.Gallery(label='Output', show_label=False, elem_id="gallery", height='auto')
result_gallery = gr.Gallery(label='Output', show_label=False, elem_id="gallery",
object_fit='contain', height=768)
run_button.click(fn=generate_clicked, inputs=[prompt], outputs=[result_gallery])

View File

@ -18,7 +18,7 @@ xl_refiner = core.load_model(xl_refiner_filename)
@torch.no_grad()
def process(positive_prompt, negative_prompt, width=1024, height=1024, batch_size=1):
def process(positive_prompt, negative_prompt, width=1280, height=960, batch_size=1):
positive_conditions = core.encode_prompt_condition(clip=xl_base.clip, prompt=positive_prompt)
negative_conditions = core.encode_prompt_condition(clip=xl_base.clip, prompt=negative_prompt)