Skip to content

Commit

Permalink
fix: ignore the first similar as the same
Browse files Browse the repository at this point in the history
  • Loading branch information
xnought committed Feb 1, 2024
1 parent 67d03c8 commit fed9636
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion backend/src/api/similar.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,6 @@ def get_similar_pdb(protein_name: str):
def get_similar_venome(protein_name: str):
query_name = pdb_file_name(protein_name)
target_folder = "src/data/pdbAlphaFold/"
similar = easy_search(query_name, target_folder, out_format="target,prob")
# the first will always be the query itself so we skip it
similar = easy_search(query_name, target_folder, out_format="target,prob")[1:]
return [SimilarProtein(name=revert_pdb_filename(s[0]), prob=s[1]) for s in similar]

0 comments on commit fed9636

Please sign in to comment.