Skip to content

Error "struct.error: i format requires -xxx <= number <= xxx" solved by split FASTQ, but how to combine results? #93

Closed

Description

@heathergeiger

Got the following error while trying to run an ADT (protein) library with ~170 million reads:

struct.error: 'i' format requires -2147483648 <= number <= 2147483647

Per issue 75 (#75), I assumed that the error was due to having too many reads in the library. This made sense since my other library that had only ~100 million reads ran fine.

I split the library into two sets of ~85 million reads using Unix split, and each set ran fine after that.

My question is, how should I combine the results of CITE-Seq-Count run on each half of the FASTQs? I was just going to sum them, but I realize that this could result in overestimating UMI counts. If a given cell barcode has the same UMI counted once each in the first half of the FASTQs and the second half, summing would result in double counting.

So maybe it would make more sense to randomly downsample the FASTQ down to ~100 million, and just run the downsample through CITE-Seq-Count?

Obviously the ideal thing wold be to just run everything at once, but not sure how simple a fix it would be to get it running without subsetting the reads. If it helps, we have access to a cluster with a good amount of memory if needed.

Activity

  1. Hoohm commented on Nov 11, 2019

    @Hoohm
    Owner

    Hello @heathergeiger
    This might be a bigger issue depending on where the error pops up. Could you paste the whole error in here?

    You are right, you will see an overinflation of the umi counts, so that is not the best solution.

    Now that CSC allows for multiple lanes, ie, running multiple subset of one library together, maybe you can split it even further in 4 ?

    I'm afraid of memory issues though.

    First paste the whole error here and I will check if I can change part of the code to help.

  2. heathergeiger commented on Nov 12, 2019

    @heathergeiger
    Author

    Process ForkPoolWorker-1:
    Traceback (most recent call last):
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/pool.py", line 127, in worker
    put((job, i, result))
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/queues.py", line 367, in put
    self._writer.send_bytes(obj)
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/connection.py", line 203, in send_bytes
    self._send_bytes(m[offset:offset + size])
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/connection.py", line 396, in _send_bytes
    header = struct.pack("!i", n)
    struct.error: 'i' format requires -2147483648 <= number <= 2147483647

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/process.py", line 297, in _bootstrap
    self.run()
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/process.py", line 99, in run
    self._target(*self._args, **self._kwargs)
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/pool.py", line 132, in worker
    put((job, i, (False, wrapped)))
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/queues.py", line 367, in put
    self._writer.send_bytes(obj)
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/connection.py", line 203, in send_bytes
    self._send_bytes(m[offset:offset + size])
    File "/nfs/sw/citeseqcount/citeseqcount-1.4.2-dev2/python/lib/python3.7/site-packages/multiprocess-0.70.7-py3.7-linux-x86_64.egg/multiprocess/connection.py", line 396, in _send_bytes
    header = struct.pack("!i", n)
    struct.error: 'i' format requires -2147483648 <= number <= 2147483647

    These errors are repeated for ForkPoolWorker-2, ForkPoolWorker-3, and ForkPoolWorker-4 (since I ran CITE-Seq-Count with -T 4).

  3. heathergeiger commented on Nov 12, 2019

    @heathergeiger
    Author

    For the record I was able to run successfully on a random downsample down to ~110 million reads from the 171 million.

    I'm also going to try running now on the full set of reads, simply increasing the number of cores from 4 to 8 so that each core only has to handle <22M reads instead of over 42M.

  4. heathergeiger commented on Nov 12, 2019

    @heathergeiger
    Author

    Edit: 8 cores worked great!

  5. heathergeiger commented on Nov 12, 2019

    @heathergeiger
    Author

    So seems like the problem comes when you try to run too many reads all on the same node?

  6. Hoohm commented on Nov 13, 2019

    @Hoohm
    Owner

    Yes, there might be a way to calculate this and propose a good number of cores to users

  7. heathergeiger commented on Apr 13, 2020

    @heathergeiger
    Author

    Realize I forgot to close this issue before. Sorry about that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions