Attention une mise à jour du serveur va être effectuée le lundi 17 mai entre 13h et 13h30. Cette mise à jour va générer une interruption du service de quelques minutes.

Commit def760d8 authored by Mikaël Salson's avatar Mikaël Salson

segment: CDR3/Junction JSON output could be falsely set

When JUNCTIONstart or JUNCTIONend equaled 0, their values
were not modified. But the CDR3/Junction are output in the JSON
as long as the values of the variables are >= 0 (maybe this
should also have been modified). Therefore we could have weird results
with JUNCTIONstart=0 and JUNCTIONend=40.

Tests added.
parent 16c5abab
......@@ -1166,8 +1166,11 @@ void FineSegmenter::findCDR3(){
// There are two cases when we can not detect a JUNCTION/CDR3:
// - Germline V or J gene has no 'marked_pos'
// - Sequence may be too short on either side, and thus the backtrack did not find a suitable 'marked_pos'
if (JUNCTIONstart == 0 || JUNCTIONend == 0)
if (JUNCTIONstart == 0 || JUNCTIONend == 0) {
JUNCTIONstart = -1 ;
JUNCTIONend = -1 ;
// We require at least two codons
if (JUNCTIONend - JUNCTIONstart + 1 < 6) {
# The sequences are on TRG, no CDR3 should be found with IGH
!LAUNCH: $VIDJIL_DIR/vidjil $VIDJIL_DEFAULT_OPTIONS -c segment -3 -V $VIDJIL_DIR/germline/IGHV.fa -D $VIDJIL_DIR/germline/IGHD.fa -J $VIDJIL_DIR/germline/IGHJ.fa $VIDJIL_DIR/algo/tests/should-vdj-tests/cdr3-indels.should-vdj.fa; cat out/cdr3-indels.should-vdj.vidjil
$ No CDR3 should be found
0:TRGV.* [{].*[}]
$ No CDR3 in JSON
0: "cdr3"
0: "junction"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment