try esm fold
Browse files
app.py
CHANGED
@@ -191,14 +191,20 @@ def display_protein():
|
|
191 |
sequence = st.text_input('Enter the amino-acid sequence of the query protein target', value='HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA', placeholder='HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA')
|
192 |
|
193 |
if sequence:
|
194 |
-
model
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
200 |
|
201 |
-
st.write(
|
202 |
|
203 |
"""
|
204 |
sequence = st.text_input("Enter the amino-acid sequence of the query protein target", value="HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA", placeholder="HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA")
|
|
|
191 |
sequence = st.text_input('Enter the amino-acid sequence of the query protein target', value='HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA', placeholder='HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA')
|
192 |
|
193 |
if sequence:
|
194 |
+
model = esm.pretrained.esmfold_v1()
|
195 |
+
model = model.eval().cuda()
|
196 |
+
|
197 |
+
with torch.no_grad():
|
198 |
+
output = model.infer_pdb(sequence)
|
199 |
+
|
200 |
+
#with open("result.pdb", "w") as f:
|
201 |
+
# f.write(output)
|
202 |
+
|
203 |
+
|
204 |
+
#struct = bsio.load_structure("result.pdb", extra_fields=["b_factor"])
|
205 |
+
#print(struct.b_factor.mean())
|
206 |
|
207 |
+
st.write(output)
|
208 |
|
209 |
"""
|
210 |
sequence = st.text_input("Enter the amino-acid sequence of the query protein target", value="HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA", placeholder="HXHVWPVQDAKARFSEFLDACITEGPQIVSRRGAEEAVLVPIGEWRRLQAAA")
|