ICCV2023-papers / app.py
hysts's picture
hysts HF staff
Add tutorial
c867e45
raw
history blame
3.62 kB
#!/usr/bin/env python
from __future__ import annotations
import gradio as gr
from paper_list import PaperList
DESCRIPTION = "# ICCV 2023 Papers"
TUTORIAL = """\
#### Hugging Face ICCV 2023 event
Join the org using this [link](https://huggingface.co/organizations/ICCV2023/share/BXikCrBMdmnKzsFjVSulFrCsQAujoYGiNG).
ICCV 2023 organization is accepting paper claims from authors attending ICCV 2023.
This organization invites participants to claim their ICCV 2023 papers, upload models and datasets, and to
build their Gradio demos for conference papers on Hugging Face.
#### Hugging Face Paper Pages ICCV 2023
- ICCV 2023 Paper Pages will allow authors to claim their papers on Hugging Face. Claiming papers on
ICCV 2023 organization will allow people to find artifacts related to a paper such as models, datasets
and Gradio demos (in form of Spaces). This also enables the community to discuss about the paper.
#### Tutorial for claiming the ICCV 2023 papers
Visit the [demo](https://huggingface.co/spaces/ICML2023/ICML2023_papers) and find your paper, to claim your paper
see the guide [here](https://huggingface.co/docs/hub/paper-pages#claiming-authorship-to-a-paper) and to get started
with adding models [here](https://huggingface.co/docs/hub/models-uploading).
If your paper is not yet indexed on Hugging Face, you can index it by following this
[guide](https://huggingface.co/docs/hub/paper-pages#can-i-have-a-paper-page-even-if-i-have-no-modeldatasetspace)
and open a [PR](https://huggingface.co/spaces/ICCV2023/ICCV2023-papers/discussions) to add your paper to the
Hugging Face demo.
The Hub will automatically match paper to users based on their email.
If your paper is not linked to your account, you can click in your name in the corresponding Paper page and
click “claim authorship”. This will automatically re-direct to your paper settings where you can confirm the request.
The admin team will validate your request soon. Once confirmed, the Paper page will show as verified.
"""
paper_list = PaperList()
with gr.Blocks(css="style.css") as demo:
gr.Markdown(DESCRIPTION)
with gr.Accordion(label="Tutorial", open=False):
gr.Markdown(TUTORIAL)
search_box = gr.Textbox(
label="Search Title", placeholder="You can search for titles with regular expressions. e.g. (?<!sur)face"
)
case_sensitive = gr.Checkbox(label="Case Sensitive")
filter_names = gr.CheckboxGroup(
choices=[
"arXiv",
"GitHub",
"Space",
"Model",
"Dataset",
],
label="Filter",
)
search_button = gr.Button("Search")
number_of_papers = gr.Textbox(label="Number of Papers Found")
table = gr.HTML(show_label=False)
demo.load(
fn=paper_list.render,
inputs=[
search_box,
case_sensitive,
filter_names,
],
outputs=[
number_of_papers,
table,
],
api_name=False,
)
search_box.submit(
fn=paper_list.render,
inputs=[
search_box,
case_sensitive,
filter_names,
],
outputs=[
number_of_papers,
table,
],
api_name=False,
)
search_button.click(
fn=paper_list.render,
inputs=[
search_box,
case_sensitive,
filter_names,
],
outputs=[
number_of_papers,
table,
],
api_name=False,
)
if __name__ == "__main__":
demo.queue(api_open=False).launch()