File size: 1,764 Bytes
ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 3537dc0 ee76aa3 839714d 3537dc0 ee76aa3 3537dc0 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# import sys
# root_dir = __file__.rsplit("/", 1)[0]
# if root_dir not in sys.path:
# sys.path.append(root_dir)
# import gradio as gr
# import asyncio
# import os
# from demo.modules.search import build_search_module
# from demo.modules.compute_score import build_score_computation
# from demo.modules.tmalign import build_TMalign
# # Build demo
# with gr.Blocks() as demo:
# build_search_module()
# build_score_computation()
# # build_TMalign()
# # import gradio as gr
# # import subprocess
# # def run_command(cmd: str) -> str:
# # p = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
# # stdout, stderr = p.communicate()
# # if stdout:
# # return f"[Output]\n{stdout.decode()}"
# # if stderr:
# # return f"[Error]\n{stderr.decode()}"
# # # Build the block for command line interface
# # gr.Markdown(f"# Input your command and click to run")
# # with gr.Column():
# # cmd = gr.Textbox(label="Input your command", value="echo 'Hello, World!'")
# # btn = gr.Button(value="Run")
# # output = gr.TextArea(label="Output", interactive=False)
# # btn.click(run_command, inputs=[cmd], outputs=[output])
# if __name__ == '__main__':
# # Run the demo
# demo.launch()
import gradio as gr
with gr.Blocks(title="ProTrek") as demo:
gr.Markdown("# We are working hard to build a new website for better retrieval service of ProTrek.\n\n"
"# Please move to http://search-protrek.com :)\n\n"
"# For any question, please email [email protected] & [email protected]")
if __name__ == '__main__':
# Run the demo
demo.launch()
|