as-cle-bert commited on
Commit
1fa228e
·
verified ·
1 Parent(s): b70e4e5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -91,8 +91,8 @@ def prediction(prompt, temperature):
91
  return seq, protein.sequence, html, html1, "./generation.pdb", "./round_tripped.pdb"
92
 
93
  def return_stuff(prompt, temperature):
94
- seq, protein.sequence, html, html1, pdb, pdb1 = prediction(prompt, temperature)
95
- return seq, protein.sequence, html, html1, pdb, pdb1
96
 
97
  demo = gr.Interface(fn = return_stuff, inputs = [gr.Textbox(label="Masked protein sequence", info="Use '_' as masking character", value="___________________________________________________DQATSLRILNNGHAFNVEFDDSQDKAVLKGGPLDGTYRLIQFHFHWGSLDGQGSEHTVDKKKYAAELHLVHWNTKYGDFGKAVQQPDGLAVLGIFLKVGSAKPGLQKVVDVLDSIKTKGKSADFTNFDPRGLLPESLDYWTYPGSLTTPP___________________________________________________________"), gr.Slider(0,1,label="Temperature")], outputs = [gr.Textbox(label="Originally predicted sequence"),gr.Textbox(label="Inverse folding predicted sequence"),gr.HTML(label="Predicted 3D structure"),gr.HTML(label="Inverse-folding predicted 3D structure"), Molecule3D(label="Predicted molecular structure"), Molecule3D(label="Inverse-folding predicted molecular structure")], title="""<h1 align='center'>Proteins with ESM</h1>
98
  <h2 align='center'>Predict the whole sequence and 3D structure of masked protein sequences!</h2>
 
91
  return seq, protein.sequence, html, html1, "./generation.pdb", "./round_tripped.pdb"
92
 
93
  def return_stuff(prompt, temperature):
94
+ seq, sequence, html, html1, pdb, pdb1 = prediction(prompt, temperature)
95
+ return seq, sequence, html, html1, pdb, pdb1
96
 
97
  demo = gr.Interface(fn = return_stuff, inputs = [gr.Textbox(label="Masked protein sequence", info="Use '_' as masking character", value="___________________________________________________DQATSLRILNNGHAFNVEFDDSQDKAVLKGGPLDGTYRLIQFHFHWGSLDGQGSEHTVDKKKYAAELHLVHWNTKYGDFGKAVQQPDGLAVLGIFLKVGSAKPGLQKVVDVLDSIKTKGKSADFTNFDPRGLLPESLDYWTYPGSLTTPP___________________________________________________________"), gr.Slider(0,1,label="Temperature")], outputs = [gr.Textbox(label="Originally predicted sequence"),gr.Textbox(label="Inverse folding predicted sequence"),gr.HTML(label="Predicted 3D structure"),gr.HTML(label="Inverse-folding predicted 3D structure"), Molecule3D(label="Predicted molecular structure"), Molecule3D(label="Inverse-folding predicted molecular structure")], title="""<h1 align='center'>Proteins with ESM</h1>
98
  <h2 align='center'>Predict the whole sequence and 3D structure of masked protein sequences!</h2>