hasindu2008/slow5tools

Option to retain directory structure

mbhall88 opened this issue · 3 comments

Hi,

Would it be possible to add a feature to allow for maintaining directory structure when converting between slow5 and fast5?

For example, if I have a directory structure

  └── Vero
     ├── Vero_C_2hpi
     │  └── 20200513_Vero_c_2hpi
     │     ├── fast5
     │     │  ├── fast5_fail
     │     │  └── fast5_pass
     ├── Vero_C_24hpi
     │  ├── 20200430_Vero_c_24hpi
     │  │  └── 20200430_Vero_c_24hpi
     │  │     └── 20200430_0856_MN28696_FAN24843_c1ec9e3c
     │  │        ├── fast5

it would be nice if I could have the output directory mirror this.

For example, if I run

$ slow5tools s2f -d out/ Vero/

Then all of the fast5 files are dumped in out/. I would be great to have an option to have them dumped in the same nested structure as the input directory.

Thanks for the great tool!

Hi @mbhall88

This feature is being already implemented (we ourselves wanted this requirement while converting some of our archive data). The implementation is here #51 but have not yet been tested thoroughly. Will be merged to the dev branch soon after a test.

Regards

This feature for f2s is available in the master branch. Give it a go and let us know your thoughts.

Seems to be working based on a test I just ran 🎉