Skip to content

Commit

Permalink
add gradio demos
Browse files Browse the repository at this point in the history
  • Loading branch information
Mountchicken committed Nov 26, 2024
1 parent f3b879f commit 40e6401
Show file tree
Hide file tree
Showing 6 changed files with 501 additions and 14 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -604,6 +604,18 @@ TMPDIR='/tmp' python gradio_demos/upn_demo.py


## 4.2 Gradio Demo for ChatRex
We also provide a gradio demo for ChatRex.
```bash
python gradio_demos/chatrex_demo.py
# if there is permission error, please run the following command
mkdir tmp
TMPDIR='/tmp' python gradio_demos/upn_demo.py
```

<div align=center>
<img src="assets/chatrex_gradio.jpg" width=600 >
</div>



# 5. LICENSE
Expand Down
Binary file added assets/chatrex_gradio.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions chatrex/tools/prompt_templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@


REGION_CAPTION_SINGLE_REGION_BREIFLY_STAGE2 = [
"Can you provide me with a brief description of [OBJ]? Answer the question with brief description."
"Can you provide me with a brief description of [OBJ]? Answer the question with brief description.",
"Give a brief description of [OBJ].",
"What brief description can you provide for [OBJ]?",
"Provide a brief description for [OBJ].",
Expand Down Expand Up @@ -125,7 +125,7 @@
]

BREIF_CAPTION_WITH_GROUDING_STAGE2 = [
"Please breifly describe this image in one sentence and detect all the mentioned objects. Answer the question with grounded answer."
"Please breifly describe this image in one sentence and detect all the mentioned objects. Answer the question with grounded answer.",
"Please briefly describe this image and detect all the mentioned objects. Answer with grounded object indexes.",
"Breifly describe this image with grounded answer",
"Provide a brief description of this image and detect the objects mentioned in the description.",
Expand Down
Loading

0 comments on commit 40e6401

Please sign in to comment.