Spaces:
Sleeping
Sleeping
minor bug fix
Browse files
app.py
CHANGED
@@ -231,11 +231,11 @@ def process_family_sequence(protein_fasta):
|
|
231 |
probabilitiesfam = F.softmax(logitsfam, dim=1)
|
232 |
_, predicted_labelsfam = torch.max(logitsfam, dim=1)
|
233 |
|
234 |
-
decoded_labelsfam =
|
235 |
family_info = get_family_info(decoded_labelsfam[0])
|
236 |
|
237 |
figfam = plt.figure(figsize=(10, 5))
|
238 |
-
labelsfam =
|
239 |
probabilitiesfam = probabilitiesfam.tolist()
|
240 |
|
241 |
# Convert the nested list to a flat list of probabilities
|
|
|
231 |
probabilitiesfam = F.softmax(logitsfam, dim=1)
|
232 |
_, predicted_labelsfam = torch.max(logitsfam, dim=1)
|
233 |
|
234 |
+
decoded_labelsfam = yfam.inverse_transform(predicted_labelsfam.tolist())
|
235 |
family_info = get_family_info(decoded_labelsfam[0])
|
236 |
|
237 |
figfam = plt.figure(figsize=(10, 5))
|
238 |
+
labelsfam = yfam.classes_
|
239 |
probabilitiesfam = probabilitiesfam.tolist()
|
240 |
|
241 |
# Convert the nested list to a flat list of probabilities
|