Giter VIP home page Giter VIP logo

Comments (6)

mizraelson avatar mizraelson commented on July 19, 2024

Hi, thank you for reporting this! Can you please try the latest develop version and compare the outputs. We have identified and fixed one bug that have potentially caused the issue. Let me know if it helped!

from mixcr.

vincentwalter avatar vincentwalter commented on July 19, 2024

It's better but not completely solved.
I reran with the release (c9fafa41fe) and the develop version (b0900b576f):

vwalter@work:~/projects/playground$ R1=path/to/R1.fastq.gz
vwalter@work:~/projects/playground$ R2=path/to/R2.fastq.gz
vwalter@work:~/projects/playground$ OUT=path/to/output
vwalter@work:~/projects/playground$ samtools import -i -1 $R1 -2 $R2 --order ro -O bam,level=0 | \
    samtools sort -@10 -M -o "${OUT}.bam" -
vwalter@work:~/projects/playground$ mixcr analyze cellecta-human-rna-xcr-umi-drivermap-air -Xmx100g $R1 $R2 "${OUT}_fastq_c9fafa41fe"
vwalter@work:~/projects/playground$ ./mixcr analyze cellecta-human-rna-xcr-umi-drivermap-air -Xmx100g $R1 $R2 "${OUT}_fastq_b0900b576f"
vwalter@work:~/projects/playground$ mixcr analyze cellecta-human-rna-xcr-umi-drivermap-air -Xmx100g "${OUT}.bam" "${OUT}_bam_c9fafa41fe"
vwalter@work:~/projects/playground$ ./mixcr analyze cellecta-human-rna-xcr-umi-drivermap-air -Xmx100g "${OUT}.bam" "${OUT}_bam_b0900b576f"

The differences get smaller:

vwalter@work:~/projects/playground$ ./mixcr clonesDiff -c "${OUT}_fastq_c9fafa41fe.clns" "${OUT}_bam_c9fafa41fe.clns"
Unique clones in cloneset 1: 439 (0.19%)
Reads in unique clones in cloneset 1: 2584 (0.05%)
Unique clones in cloneset 2: 131 (0.06%)
Reads in unique clones in cloneset 2: 1025 (0.02%)
vwalter@work:~/projects/playground$ ./mixcr clonesDiff -c "${OUT}_fastq_b0900b576f.clns" "${OUT}_bam_b0900b576f.clns"
Unique clones in cloneset 1: 155 (0.07%)
Reads in unique clones in cloneset 1: 962 (0.02%)
Unique clones in cloneset 2: 111 (0.05%)
Reads in unique clones in cloneset 2: 721 (0.01%)

However, is it expected, that the clns files differ this drastically between versions ?

vwalter@work:~/projects/playground$ ./mixcr clonesDiff -c "${OUT}_fastq_c9fafa41fe.clns" "${OUT}_fastq_b0900b576f.clns"
Unique clones in cloneset 1: 226519 (99.98%)
Reads in unique clones in cloneset 1: 4817261 (99.99%)
Unique clones in cloneset 2: 226488 (99.98%)
Reads in unique clones in cloneset 2: 4817734 (99.99%)
vwalter@work:~/projects/playground$ ./mixcr clonesDiff -c "${OUT}_bam_c9fafa41fe.clns" "${OUT}_bam_b0900b576f.clns"
Unique clones in cloneset 1: 226222 (99.99%)
Reads in unique clones in cloneset 1: 4798599 (99.99%)
Unique clones in cloneset 2: 226455 (99.99%)
Reads in unique clones in cloneset 2: 4817078 (99.99%)

from mixcr.

mizraelson avatar mizraelson commented on July 19, 2024

Hi,

If you could share the input files, I can investigate further. Generally, for reads that have low similarity to the reference, the randomized part of the alignment algorithm can play a bigger role. There is a seed that is calculated from the ID and the header of every read; this seed will differ in BAM and FASTQ formats. For reads that align well with the reference, this does not affect the outcome.

Regarding the difference between the two versions, some algorithms have improved, and the output results can slightly differ and be more reliable. From the numbers you have shared, the difference is less than 0.5%.

from mixcr.

vincentwalter avatar vincentwalter commented on July 19, 2024

I sent a link to the files to [email protected].

About the difference in clonesets between the two versions. Where do you get the less than 0.5%?
The output says Unique clones in cloneset 1: 226222 (99.99%) so I was under the impression that almost no overlap exists between the clonesets generated with the different versions.

from mixcr.

mizraelson avatar mizraelson commented on July 19, 2024

Hi, thank you for sharing the data. We have identified the reason for the remaining difference between BAM and FASTQ. It is due to the way nucleotide wildcards are resolved. This algorithm requires randomization which comes from different seeds in bam and fastq files. We will fix this issue in the upcoming release but it only affects a very small fraction of reads.

As for the difference between the versions, the clonesDiff function relies on full sets of gene hits. For example:

  1. IGHD2-2*00(40),IGHD3-22*00(36),IGHD4-11*00(35)
  2. IGHD2-2*00(40),IGHD3-22*00(36),IGHD1-26*00(35)

The clones above will be considered different because of the last D gene hit. But if you compare the samples using the best hit for every gene (IGHD2-2*00 in the example above), all clones will be identical.

from mixcr.

vincentwalter avatar vincentwalter commented on July 19, 2024

Thank you for looking into it!

from mixcr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.