Spaces:
Runtime error
Runtime error
Move token index entry to advanced options
Browse files
app.py
CHANGED
|
@@ -352,26 +352,25 @@ def main():
|
|
| 352 |
label="Text prompt",
|
| 353 |
placeholder=PROMPT1,
|
| 354 |
)
|
| 355 |
-
|
| 356 |
subject_sub_prompts = gr.Textbox(
|
| 357 |
-
|
| 358 |
-
|
| 359 |
-
)
|
| 360 |
-
|
| 361 |
-
subject_token_indices = gr.Textbox(
|
| 362 |
-
label="Optional: The token indices of each subject (separate indices for the same subject with commas, and for different subjects with semicolons)",
|
| 363 |
-
placeholder=SUBJECT_TOKEN_INDICES1,
|
| 364 |
-
)
|
| 365 |
-
|
| 366 |
-
filter_token_indices = gr.Textbox(
|
| 367 |
-
label="Optional: The token indices to filter, i.e. conjunctions, numbers, postional relations, etc. (if left empty, this will be automatically inferred)",
|
| 368 |
-
placeholder=FILTER_TOKEN_INDICES1,
|
| 369 |
-
)
|
| 370 |
-
|
| 371 |
-
num_tokens = gr.Textbox(
|
| 372 |
-
label="Optional: The number of tokens in the prompt (We use this to verify your input, as sometimes rare words are split into more than one token)",
|
| 373 |
-
placeholder=NUM_TOKENS1,
|
| 374 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 375 |
|
| 376 |
with gr.Row():
|
| 377 |
sketchpad = gr.Sketchpad(label="Sketch Pad (draw each bounding box in a different layer)")
|
|
|
|
| 352 |
label="Text prompt",
|
| 353 |
placeholder=PROMPT1,
|
| 354 |
)
|
|
|
|
| 355 |
subject_sub_prompts = gr.Textbox(
|
| 356 |
+
label="Sub-prompts for each subject (separate with semicolons)",
|
| 357 |
+
placeholder=SUBJECT_SUB_PROMPTS1,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 358 |
)
|
| 359 |
+
with gr.Accordion("Advanced options", open=False):
|
| 360 |
+
subject_token_indices = gr.Textbox(
|
| 361 |
+
label="Optional: The token indices of each subject (separate indices for the same subject with commas, and for different subjects with semicolons)",
|
| 362 |
+
placeholder=SUBJECT_TOKEN_INDICES1,
|
| 363 |
+
)
|
| 364 |
+
|
| 365 |
+
filter_token_indices = gr.Textbox(
|
| 366 |
+
label="Optional: The token indices to filter, i.e. conjunctions, numbers, postional relations, etc. (if left empty, this will be automatically inferred)",
|
| 367 |
+
placeholder=FILTER_TOKEN_INDICES1,
|
| 368 |
+
)
|
| 369 |
+
|
| 370 |
+
num_tokens = gr.Textbox(
|
| 371 |
+
label="Optional: The number of tokens in the prompt (We use this to verify your input, as sometimes rare words are split into more than one token)",
|
| 372 |
+
placeholder=NUM_TOKENS1,
|
| 373 |
+
)
|
| 374 |
|
| 375 |
with gr.Row():
|
| 376 |
sketchpad = gr.Sketchpad(label="Sketch Pad (draw each bounding box in a different layer)")
|