NREL / EvoProtGrad

Directed evolution of proteins in sequence space with gradients
https://nrel.github.io/EvoProtGrad/
BSD 3-Clause "New" or "Revised" License
45 stars 7 forks source link

Check for size of preserved region fixed to reflect 1 AA instead of 2 #6

Closed EvanKomp closed 1 month ago

EvanKomp commented 1 month ago

Line 71 asserts that the difference in start to end is greater than 1, but line 187, which applies the mask at sample time, apples end inclusively. Thus if the user wants to preserve a single amino acid at pos, they would need to pass [ pos, pos] which is caught by the assert.

Changed the check to be < 0 to allow for single amino acid preserved regions.