Spaces:
Runtime error
Runtime error
wnagleiofficial
commited on
Commit
·
ae25438
1
Parent(s):
fe55e9c
fix app single
Browse files
app.py
CHANGED
|
@@ -8,7 +8,7 @@ def classifier(peptide_seq):
|
|
| 8 |
handle = StringIO(peptide_seq)
|
| 9 |
data = []
|
| 10 |
for record in SeqIO.parse(handle, 'fasta'):
|
| 11 |
-
data.append((record.id, record.seq))
|
| 12 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 13 |
neuropeptide_pred = predict(data, './model.pth', device)
|
| 14 |
return neuropeptide_pred
|
|
|
|
| 8 |
handle = StringIO(peptide_seq)
|
| 9 |
data = []
|
| 10 |
for record in SeqIO.parse(handle, 'fasta'):
|
| 11 |
+
data.append((record.id, str(record.seq)))
|
| 12 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 13 |
neuropeptide_pred = predict(data, './model.pth', device)
|
| 14 |
return neuropeptide_pred
|