Re: parsing fastq files with D

2016-03-29 Thread rikki cattermole via Digitalmars-d-learn
On 30/03/2016 1:46 AM, eastanon wrote: On Thursday, 24 March 2016 at 06:34:51 UTC, rikki cattermole wrote: void popFront() { import std.string : indexOf; if (source is null) { isEmpty = true; return;

Re: parsing fastq files with D

2016-03-29 Thread eastanon via Digitalmars-d-learn
On Thursday, 24 March 2016 at 06:34:51 UTC, rikki cattermole wrote: void popFront() { import std.string : indexOf; if (source is null) {

Re: parsing fastq files with D

2016-03-24 Thread eastanon via Digitalmars-d-learn
On Thursday, 24 March 2016 at 13:38:32 UTC, Marc Schütz wrote: Yes, it's read into your processes memory. You can use std.mmfile [1] to make things a bit more efficient. It will, too, read the data into memory, but it will do so in a way (memory mapping) that only loads what is actually

Re: parsing fastq files with D

2016-03-24 Thread Marc Schütz via Digitalmars-d-learn
On Thursday, 24 March 2016 at 08:24:15 UTC, eastanon wrote: On Thursday, 24 March 2016 at 06:34:51 UTC, rikki cattermole wrote: As a little fun thing to do I implemented it for you. It won't allocate. Making this perfect for you. With a bit of work you could make Result have buffers for

Re: parsing fastq files with D

2016-03-24 Thread rikki cattermole via Digitalmars-d-learn
On 24/03/16 9:24 PM, eastanon wrote: On Thursday, 24 March 2016 at 06:34:51 UTC, rikki cattermole wrote: As a little fun thing to do I implemented it for you. It won't allocate. Making this perfect for you. With a bit of work you could make Result have buffers for result instead of using the

Re: parsing fastq files with D

2016-03-24 Thread eastanon via Digitalmars-d-learn
On Thursday, 24 March 2016 at 06:34:51 UTC, rikki cattermole wrote: As a little fun thing to do I implemented it for you. It won't allocate. Making this perfect for you. With a bit of work you could make Result have buffers for result instead of using the input array allow for the source to

Re: parsing fastq files with D

2016-03-24 Thread rikki cattermole via Digitalmars-d-learn
As a little fun thing to do I implemented it for you. It won't allocate. Making this perfect for you. With a bit of work you could make Result have buffers for result instead of using the input array allow for the source to be an input range itself. I made this up on dpaste and single quotes

parsing fastq files with D

2016-03-23 Thread eastanon via Digitalmars-d-learn
Fastq is a format for storing DNA sequences together with the associated quality information often encoded in ascii characters. It is typically made of 4 lines for example 2 fastq entries would look like this. @seq1 TTAAAT + ?+BBB/DHH@ @seq2 GACCCTTTGCA + ?+BHB/DIH@ I do not have a lot