Spaces:
Running
Running
Update cas12lstm.py
Browse files- cas12lstm.py +5 -1
cas12lstm.py
CHANGED
@@ -180,8 +180,12 @@ def process_gene(gene_symbol, model_path):
|
|
180 |
else:
|
181 |
print("Failed to retrieve transcripts.")
|
182 |
|
|
|
|
|
|
|
|
|
183 |
# Sort results based on prediction score (assuming score is at the 8th index)
|
184 |
-
sorted_results = sorted(
|
185 |
|
186 |
# Return the sorted output, combined gene sequences, and all exons
|
187 |
return sorted_results, all_gene_sequences, all_exons
|
|
|
180 |
else:
|
181 |
print("Failed to retrieve transcripts.")
|
182 |
|
183 |
+
output = []
|
184 |
+
for result in results:
|
185 |
+
for item in result:
|
186 |
+
output.append(item)
|
187 |
# Sort results based on prediction score (assuming score is at the 8th index)
|
188 |
+
sorted_results = sorted(output, key=lambda x: x[8], reverse=True)
|
189 |
|
190 |
# Return the sorted output, combined gene sequences, and all exons
|
191 |
return sorted_results, all_gene_sequences, all_exons
|