bebop / poly

A Go package for engineering organisms.
https://pkg.go.dev/github.com/bebop/poly
MIT License
665 stars 70 forks source link

Slow5 #298

Closed Koeng101 closed 1 year ago

Koeng101 commented 1 year ago

This PR will add a slow5 format parser, from https://github.com/hasindu2008/slow5tools

Doesn't have a blow5 parser, but slow5 is good enough for my use case - @TimothyStiles could I get a review?

Koeng101 commented 1 year ago

I should probably add a writer as well... thoughts @TimothyStiles ?

TimothyStiles commented 1 year ago

@Koeng101 - This is freakin' sweet and a writer for this would be excellent.

@matiasinsaurralde is right when it comes to strings that are repeated a lot. Just name the constant something close to the string. Makes it easier to tab complete and not have to worry about typos.

Koeng101 commented 1 year ago

right when it comes to strings that are repeated a lot

They're only used once. I'll make a writer though!

Koeng101 commented 1 year ago

96.4% test coverage (the only things I don't test is the writing-bits of the write function, because it is difficult to test that.)

Last rewrite was quite large - I made the parser similar to the fasta parser method developed by @soypat in #284 . I agree, it is a lot clearer!