Skip to content

Commit

Permalink
fix rbh logic by removing resAB_sort process (#685)
Browse files Browse the repository at this point in the history
  • Loading branch information
StephanieSKim authored Mar 23, 2023
1 parent 6b93884 commit 3bcbdba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
9 changes: 1 addition & 8 deletions data/workflow/rbh.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,10 @@ if [ ! -e "${TMP_PATH}/resBA.dbtype" ]; then
fi


# sort A->B by decreasing bitscores:
if [ ! -e "${TMP_PATH}/resAB_sorted.dbtype" ]; then
# shellcheck disable=SC2086
"$MMSEQS" filterdb "${TMP_PATH}/resAB" "${TMP_PATH}/resAB_sorted" --sort-entries 2 --filter-column 2 ${THREADS_COMP_PAR} \
|| fail "sort resAB by bitscore died"
fi

# extract a single best hit in A->B direction (used to take best bitscore for A):
if [ ! -e "${TMP_PATH}/resA_best_B.dbtype" ]; then
# shellcheck disable=SC2086
"$MMSEQS" filterdb "${TMP_PATH}/resAB_sorted" "${TMP_PATH}/resA_best_B" --extract-lines 1 ${THREADS_COMP_PAR} \
"$MMSEQS" filterdb "${TMP_PATH}/resAB" "${TMP_PATH}/resA_best_B" --extract-lines 1 ${THREADS_COMP_PAR} \
|| fail "extract A best B died"
fi

Expand Down
5 changes: 3 additions & 2 deletions src/util/result2rbh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,9 @@ int result2rbh(int argc, const char **argv, const Command &command) {
} else {
// this is a B->A line - the bitscore can only decrease:
if (bestAtoBbitScore < currAlnScore) {
Debug(Debug::ERROR) << "The merged results are assumed to be sorted by decreasing bitscore.\n";
EXIT(EXIT_FAILURE);
//Debug(Debug::ERROR) << "The merged results are assumed to be sorted by decreasing bitscore.\n";
//EXIT(EXIT_FAILURE);
break;
}
if (currAlnScore < bestAtoBbitScore) {
// worse bitscore - no need to check anymore...
Expand Down

0 comments on commit 3bcbdba

Please sign in to comment.