Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing cases where mutations are introduced although they do not pass the pssm_threshold #56

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

LiorZ
Copy link

@LiorZ LiorZ commented Jul 3, 2023

The following line:
probs_masked+=probs*0.001

May introduce mutations that are below the pssm threshold.

For example, when probs[i,j] =~ 1 (close to 1) and probs[i,k] = 0 (for k!=j) but the pssm_log_odds_mask[i,j]=0 , the forbbiden aa may still be introduced since now:
probs_masked[i,j] =~ 0.001 and probs_masked[i,k] = 0 for k!=j

Then after normalization occurs:
probs = probs_masked/torch.sum(probs_masked, dim=-1, keepdim=True) #[B, 21]

probs[i,j] = 1 now , although it doesn't cross the PSSM threshold.

Is that a bug or a feature? :-D
Meaning, if pssm_log_odds_mask[i,j] = 0 then probs_masked[i,j] = 0 too right?

probs_masked+=probs*0.001 introduced mutations that didn't pass the pssm_threshold.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant