Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -622,6 +622,9 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
622 |
# ์์ฑ ๋ฒํผ
|
623 |
create_btn = gr.Button("๐งฌ ํ์ด๋ก ์์ฑ!", variant="primary", scale=2)
|
624 |
|
|
|
|
|
|
|
625 |
with gr.TabItem("๐งฌ ํ์ด๋ก DNA ์ค๊ณ"):
|
626 |
gr.Markdown("""
|
627 |
### ๐งช ํ์ด๋ก DNA ๊ณ ๊ธ ์ค์
|
@@ -683,10 +686,6 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
683 |
label="๊ณ ๋ฆฌํ ๊ตฌ์กฐ ๋น์จ",
|
684 |
visible=True
|
685 |
)
|
686 |
-
|
687 |
-
|
688 |
-
design_btn = gr.Button("๐งฌ DNA ์ค๊ณ ์์ฑ!", variant="primary", scale=2)
|
689 |
-
|
690 |
|
691 |
# ์๋ฏธ๋
ธ์ฐ ๊ตฌ์ฑ ์ค์ ์ถ๊ฐ
|
692 |
with gr.Accordion(label='๐งฌ DNA ๊ตฌ์ฑ ์ค์ ', open=False):
|
@@ -740,6 +739,10 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
740 |
label='๋
ธ์ด์ฆ ํ์
',
|
741 |
value='normal'
|
742 |
)
|
|
|
|
|
|
|
|
|
743 |
|
744 |
with gr.TabItem("๐งช ํ์ด๋ก ์ ์ ์ ๊ฐํ"):
|
745 |
gr.Markdown("""
|
@@ -776,11 +779,8 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
776 |
preview_viewer = gr.HTML()
|
777 |
rewrite_pdb = gr.File(label='ํ์ด๋ก DNA ํ์ผ')
|
778 |
preview_btn = gr.Button("๐ ๋ฏธ๋ฆฌ๋ณด๊ธฐ", variant="secondary")
|
|
|
779 |
|
780 |
-
|
781 |
-
enhance_btn = gr.Button("โก ๊ฐํ๋ ํ์ด๋ก ์์ฑ!", variant="primary", scale=2)
|
782 |
-
|
783 |
-
|
784 |
with gr.TabItem("๐ ํ์ด๋ก ๊ฐ๋ฌธ"):
|
785 |
gr.Markdown("""
|
786 |
### ๐ฐ ์๋ํ ํ์ด๋ก ๊ฐ๋ฌธ์ ์ ์ฐ
|
@@ -798,12 +798,12 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
798 |
pssm = gr.File(label='๋ถ์๋ ๊ฐ๋ฌธ ํน์ฑ')
|
799 |
pssm_view = gr.Plot(label='๊ฐ๋ฌธ ํน์ฑ ๋ถ์ ๊ฒฐ๊ณผ')
|
800 |
pssm_gen_btn = gr.Button("โจ ๊ฐ๋ฌธ ํน์ฑ ๋ถ์", variant="secondary")
|
|
|
|
|
801 |
|
802 |
-
inherit_btn = gr.Button("๐ ๊ฐ๋ฌธ์ ํ ๊ณ์น!", variant="primary", scale=2)
|
803 |
|
804 |
|
805 |
|
806 |
-
|
807 |
with gr.Column():
|
808 |
gr.Markdown("## ๐ฆธโโ๏ธ ํ์ด๋ก ํ๋กํ")
|
809 |
|
@@ -823,7 +823,7 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
823 |
gr.Markdown("#### ๐ฌ DNA ๊ตฌ์กฐ")
|
824 |
output_viewer = gr.HTML()
|
825 |
|
826 |
-
# ์ด๋ฒคํธ ์ฐ๊ฒฐ
|
827 |
seq_opt.change(
|
828 |
fn=toggle_seq_input,
|
829 |
inputs=[seq_opt],
|
@@ -838,33 +838,68 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
838 |
queue=False
|
839 |
)
|
840 |
|
841 |
-
|
842 |
-
|
843 |
-
# ์ด๋ฒคํธ ์ฐ๊ฒฐ
|
844 |
preview_btn.click(get_motif_preview,[pdb_id_code, contigs],[preview_viewer, rewrite_pdb])
|
845 |
pssm_gen_btn.click(get_pssm,[fasta_msa,input_pssm],[pssm_view, pssm])
|
846 |
|
847 |
-
# ๊ฐ ํญ์ ์์ฑ ๋ฒํผ ์ฐ๊ฒฐ
|
848 |
-
|
849 |
combined_generation,
|
850 |
-
inputs=[
|
851 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
852 |
)
|
853 |
|
854 |
-
|
855 |
combined_generation,
|
856 |
-
inputs=[
|
857 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
858 |
)
|
859 |
|
860 |
-
|
861 |
combined_generation,
|
862 |
-
inputs=[
|
863 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
864 |
)
|
865 |
|
866 |
-
|
867 |
-
create_btn.click(
|
868 |
combined_generation,
|
869 |
inputs=[
|
870 |
hero_name, strength, flexibility, speed, defense, hero_size, special_ability,
|
@@ -884,4 +919,4 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
|
|
884 |
)
|
885 |
|
886 |
demo.queue()
|
887 |
-
demo.launch(debug=True)
|
|
|
622 |
# ์์ฑ ๋ฒํผ
|
623 |
create_btn = gr.Button("๐งฌ ํ์ด๋ก ์์ฑ!", variant="primary", scale=2)
|
624 |
|
625 |
+
|
626 |
+
|
627 |
+
|
628 |
with gr.TabItem("๐งฌ ํ์ด๋ก DNA ์ค๊ณ"):
|
629 |
gr.Markdown("""
|
630 |
### ๐งช ํ์ด๋ก DNA ๊ณ ๊ธ ์ค์
|
|
|
686 |
label="๊ณ ๋ฆฌํ ๊ตฌ์กฐ ๋น์จ",
|
687 |
visible=True
|
688 |
)
|
|
|
|
|
|
|
|
|
689 |
|
690 |
# ์๋ฏธ๋
ธ์ฐ ๊ตฌ์ฑ ์ค์ ์ถ๊ฐ
|
691 |
with gr.Accordion(label='๐งฌ DNA ๊ตฌ์ฑ ์ค์ ', open=False):
|
|
|
739 |
label='๋
ธ์ด์ฆ ํ์
',
|
740 |
value='normal'
|
741 |
)
|
742 |
+
|
743 |
+
design_btn = gr.Button("๐งฌ DNA ์ค๊ณ ์์ฑ!", variant="primary", scale=2)
|
744 |
+
|
745 |
+
|
746 |
|
747 |
with gr.TabItem("๐งช ํ์ด๋ก ์ ์ ์ ๊ฐํ"):
|
748 |
gr.Markdown("""
|
|
|
779 |
preview_viewer = gr.HTML()
|
780 |
rewrite_pdb = gr.File(label='ํ์ด๋ก DNA ํ์ผ')
|
781 |
preview_btn = gr.Button("๐ ๋ฏธ๋ฆฌ๋ณด๊ธฐ", variant="secondary")
|
782 |
+
enhance_btn = gr.Button("โก ๊ฐํ๋ ํ์ด๋ก ์์ฑ!", variant="primary", scale=2)
|
783 |
|
|
|
|
|
|
|
|
|
784 |
with gr.TabItem("๐ ํ์ด๋ก ๊ฐ๋ฌธ"):
|
785 |
gr.Markdown("""
|
786 |
### ๐ฐ ์๋ํ ํ์ด๋ก ๊ฐ๋ฌธ์ ์ ์ฐ
|
|
|
798 |
pssm = gr.File(label='๋ถ์๋ ๊ฐ๋ฌธ ํน์ฑ')
|
799 |
pssm_view = gr.Plot(label='๊ฐ๋ฌธ ํน์ฑ ๋ถ์ ๊ฒฐ๊ณผ')
|
800 |
pssm_gen_btn = gr.Button("โจ ๊ฐ๋ฌธ ํน์ฑ ๋ถ์", variant="secondary")
|
801 |
+
inherit_btn = gr.Button("๐ ๊ฐ๋ฌธ์ ํ ๊ณ์น!", variant="primary", scale=2)
|
802 |
+
|
803 |
|
|
|
804 |
|
805 |
|
806 |
|
|
|
807 |
with gr.Column():
|
808 |
gr.Markdown("## ๐ฆธโโ๏ธ ํ์ด๋ก ํ๋กํ")
|
809 |
|
|
|
823 |
gr.Markdown("#### ๐ฌ DNA ๊ตฌ์กฐ")
|
824 |
output_viewer = gr.HTML()
|
825 |
|
826 |
+
# ์ด๋ฒคํธ ์ฐ๊ฒฐ
|
827 |
seq_opt.change(
|
828 |
fn=toggle_seq_input,
|
829 |
inputs=[seq_opt],
|
|
|
838 |
queue=False
|
839 |
)
|
840 |
|
|
|
|
|
|
|
841 |
preview_btn.click(get_motif_preview,[pdb_id_code, contigs],[preview_viewer, rewrite_pdb])
|
842 |
pssm_gen_btn.click(get_pssm,[fasta_msa,input_pssm],[pssm_view, pssm])
|
843 |
|
844 |
+
# ๊ฐ ํญ์ ์์ฑ ๋ฒํผ ์ฐ๊ฒฐ
|
845 |
+
create_btn.click(
|
846 |
combined_generation,
|
847 |
+
inputs=[
|
848 |
+
hero_name, strength, flexibility, speed, defense, hero_size, special_ability,
|
849 |
+
sequence, seq_len, helix_bias, strand_bias, loop_bias,
|
850 |
+
secondary_structure, aa_bias, aa_bias_potential,
|
851 |
+
num_steps, noise, hydrophobic_target_score, hydrophobic_potential,
|
852 |
+
contigs, pssm, seq_mask, str_mask, rewrite_pdb
|
853 |
+
],
|
854 |
+
outputs=[
|
855 |
+
hero_stats,
|
856 |
+
hero_description,
|
857 |
+
output_seq,
|
858 |
+
output_pdb,
|
859 |
+
output_viewer,
|
860 |
+
plddt_plot
|
861 |
+
]
|
862 |
)
|
863 |
|
864 |
+
design_btn.click(
|
865 |
combined_generation,
|
866 |
+
inputs=[
|
867 |
+
hero_name, strength, flexibility, speed, defense, hero_size, special_ability,
|
868 |
+
sequence, seq_len, helix_bias, strand_bias, loop_bias,
|
869 |
+
secondary_structure, aa_bias, aa_bias_potential,
|
870 |
+
num_steps, noise, hydrophobic_target_score, hydrophobic_potential,
|
871 |
+
contigs, pssm, seq_mask, str_mask, rewrite_pdb
|
872 |
+
],
|
873 |
+
outputs=[
|
874 |
+
hero_stats,
|
875 |
+
hero_description,
|
876 |
+
output_seq,
|
877 |
+
output_pdb,
|
878 |
+
output_viewer,
|
879 |
+
plddt_plot
|
880 |
+
]
|
881 |
)
|
882 |
|
883 |
+
enhance_btn.click(
|
884 |
combined_generation,
|
885 |
+
inputs=[
|
886 |
+
hero_name, strength, flexibility, speed, defense, hero_size, special_ability,
|
887 |
+
sequence, seq_len, helix_bias, strand_bias, loop_bias,
|
888 |
+
secondary_structure, aa_bias, aa_bias_potential,
|
889 |
+
num_steps, noise, hydrophobic_target_score, hydrophobic_potential,
|
890 |
+
contigs, pssm, seq_mask, str_mask, rewrite_pdb
|
891 |
+
],
|
892 |
+
outputs=[
|
893 |
+
hero_stats,
|
894 |
+
hero_description,
|
895 |
+
output_seq,
|
896 |
+
output_pdb,
|
897 |
+
output_viewer,
|
898 |
+
plddt_plot
|
899 |
+
]
|
900 |
)
|
901 |
|
902 |
+
inherit_btn.click(
|
|
|
903 |
combined_generation,
|
904 |
inputs=[
|
905 |
hero_name, strength, flexibility, speed, defense, hero_size, special_ability,
|
|
|
919 |
)
|
920 |
|
921 |
demo.queue()
|
922 |
+
demo.launch(debug=True)
|