keyan/te_u/paper_down_load/pdf_show.py

10 lines
218 B
Python

import gradio as gr
from gradio_pdf import PDF
with gr.Blocks() as demo:
pdf = PDF(label="Upload a PDF", interactive=True, height=800)
name = gr.Textbox()
pdf.upload(lambda f: f, pdf, name)
demo.launch()