import gradio as gr def one(text): return text if __name__ == "__main__": title = """

🔥AMP Sequence Detector

""" css = ".json {height: 527px; overflow: scroll;} .json-holder {height: 527px; overflow: scroll;}" theme = gr.themes.Soft(primary_hue="zinc", secondary_hue="blue", neutral_hue="green", text_size=gr.themes.sizes.text_lg) with gr.Blocks(css = """#col_container { margin-left: auto; margin-right: auto;} #chatbot {height: 520px; overflow: auto;}""", theme=theme) as demo: gr.Markdown("

Diff-AMP

") gr.HTML(title) gr.Markdown( "

🔥Welcome to Antimicrobial Peptide Recognition Model. See our Project

") gr.HTML( '''
Duplicate Space
''') gr.HTML( '''
🌟Note: This is an antimicrobial peptide recognition model derived from Diff-AMP, which is a branch of a comprehensive system integrating generation, recognition, and optimization. In this recognition model, you can simply input a sequence, and it will predict whether it is an antimicrobial peptide. Due to limited website capacity, we can only perform simple predictions. If you require large-scale computations, please contact my email at wangrui66677@gmail.com. Feel free to reach out if you have any questions or inquiries.
''') # gr.Markdown( # """ # # # Welcome to Antimicrobial Peptide Recognition Model # This is an antimicrobial peptide recognition model derived from Diff-AMP, which is a branch of a comprehensive system integrating generation, recognition, and optimization. In this recognition model, you can simply input a sequence, and it will predict whether it is an antimicrobial peptide. Due to limited website capacity, we can only perform simple predictions. # If you require large-scale computations, please contact my email at wangrui66677@gmail.com. Feel free to reach out if you have any questions or inquiries. # # """) # 添加示例输入和输出 examples = [ ["QGLFFLGAKLFYLLTLFL"], ["FLGLLFHGVHHVGKWIHGLIHGHH"], ["GLMSTLKGAATNAAVTLLNKLQCKLTGTC"] ] # 创建 Gradio 接口并应用美化样式和示例 iface = gr.Interface( fn=one, inputs="text", outputs="text", # title="AMP Sequence Detector", examples=examples ) gr.Markdown( "

") demo.launch()