ngs_server 0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +4 -0
- data/Gemfile +4 -0
- data/Rakefile +2 -0
- data/bin/ngs_server +58 -0
- data/data/holder.txt +0 -0
- data/ext/bamtools/CMakeLists.txt +49 -0
- data/ext/bamtools/LICENSE +22 -0
- data/ext/bamtools/README +60 -0
- data/ext/bamtools/Tutorial_Toolkit_BamTools-1.0.pdf +0 -0
- data/ext/bamtools/docs/Doxyfile +1601 -0
- data/ext/bamtools/extconf.rb +9 -0
- data/ext/bamtools/src/CMakeFiles/CMakeDirectoryInformation.cmake +22 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/DependInfo.cmake +13 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/build.make +65 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/cmake_clean.cmake +8 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/depend.internal +3 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/depend.make +3 -0
- data/ext/bamtools/src/CMakeFiles/SharedHeaders.dir/progress.make +2 -0
- data/ext/bamtools/src/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/CMakeLists.txt +18 -0
- data/ext/bamtools/src/ExportHeader.cmake +31 -0
- data/ext/bamtools/src/Makefile +182 -0
- data/ext/bamtools/src/api/BamAlignment.cpp +2432 -0
- data/ext/bamtools/src/api/BamAlignment.h +206 -0
- data/ext/bamtools/src/api/BamAux.h +456 -0
- data/ext/bamtools/src/api/BamConstants.h +127 -0
- data/ext/bamtools/src/api/BamIndex.h +79 -0
- data/ext/bamtools/src/api/BamMultiReader.cpp +395 -0
- data/ext/bamtools/src/api/BamMultiReader.h +126 -0
- data/ext/bamtools/src/api/BamReader.cpp +369 -0
- data/ext/bamtools/src/api/BamReader.h +117 -0
- data/ext/bamtools/src/api/BamWriter.cpp +142 -0
- data/ext/bamtools/src/api/BamWriter.h +63 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/DependInfo.cmake +14 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/build.make +80 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/cmake_clean.cmake +8 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/depend.internal +3 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/depend.make +3 -0
- data/ext/bamtools/src/api/CMakeFiles/APIHeaders.dir/progress.make +2 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/BamAlignment.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/BamMultiReader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/BamReader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/BamWriter.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/CXX.includecache +596 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/DependInfo.cmake +41 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamHeader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamProgram.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamProgramChain.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamReadGroup.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamReadGroupDictionary.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamSequence.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/SamSequenceDictionary.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/build.make +675 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/cmake_clean.cmake +32 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/cmake_clean_target.cmake +3 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/depend.internal +295 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/depend.make +295 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/flags.make +8 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamHeader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamIndexFactory_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamMultiReader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamRandomAccessController_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamReader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamStandardIndex_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamToolsIndex_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BamWriter_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/BgzfStream_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/SamFormatParser_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/SamFormatPrinter_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/internal/SamHeaderValidator_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/link.txt +2 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools-static.dir/progress.make +24 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/BamAlignment.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/BamMultiReader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/BamReader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/BamWriter.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/CXX.includecache +596 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/DependInfo.cmake +47 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamHeader.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamProgram.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamProgramChain.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamReadGroup.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamReadGroupDictionary.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamSequence.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/SamSequenceDictionary.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/build.make +677 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/cmake_clean.cmake +33 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/depend.internal +295 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/depend.make +295 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/flags.make +8 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamHeader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamIndexFactory_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamMultiReader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamRandomAccessController_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamReader_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamStandardIndex_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamToolsIndex_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BamWriter_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/BgzfStream_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/SamFormatParser_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/SamFormatPrinter_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/internal/SamHeaderValidator_p.cpp.o +0 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/link.txt +1 -0
- data/ext/bamtools/src/api/CMakeFiles/BamTools.dir/progress.make +24 -0
- data/ext/bamtools/src/api/CMakeFiles/CMakeDirectoryInformation.cmake +22 -0
- data/ext/bamtools/src/api/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/api/CMakeLists.txt +78 -0
- data/ext/bamtools/src/api/Makefile +902 -0
- data/ext/bamtools/src/api/SamConstants.h +95 -0
- data/ext/bamtools/src/api/SamHeader.cpp +184 -0
- data/ext/bamtools/src/api/SamHeader.h +68 -0
- data/ext/bamtools/src/api/SamProgram.cpp +139 -0
- data/ext/bamtools/src/api/SamProgram.h +61 -0
- data/ext/bamtools/src/api/SamProgramChain.cpp +351 -0
- data/ext/bamtools/src/api/SamProgramChain.h +85 -0
- data/ext/bamtools/src/api/SamReadGroup.cpp +221 -0
- data/ext/bamtools/src/api/SamReadGroup.h +68 -0
- data/ext/bamtools/src/api/SamReadGroupDictionary.cpp +289 -0
- data/ext/bamtools/src/api/SamReadGroupDictionary.h +86 -0
- data/ext/bamtools/src/api/SamSequence.cpp +161 -0
- data/ext/bamtools/src/api/SamSequence.h +60 -0
- data/ext/bamtools/src/api/SamSequenceDictionary.cpp +292 -0
- data/ext/bamtools/src/api/SamSequenceDictionary.h +88 -0
- data/ext/bamtools/src/api/api_global.h +21 -0
- data/ext/bamtools/src/api/cmake_install.cmake +122 -0
- data/ext/bamtools/src/api/internal/BamHeader_p.cpp +132 -0
- data/ext/bamtools/src/api/internal/BamHeader_p.h +71 -0
- data/ext/bamtools/src/api/internal/BamIndexFactory_p.cpp +112 -0
- data/ext/bamtools/src/api/internal/BamIndexFactory_p.h +49 -0
- data/ext/bamtools/src/api/internal/BamMultiMerger_p.h +297 -0
- data/ext/bamtools/src/api/internal/BamMultiReader_p.cpp +805 -0
- data/ext/bamtools/src/api/internal/BamMultiReader_p.h +103 -0
- data/ext/bamtools/src/api/internal/BamRandomAccessController_p.cpp +272 -0
- data/ext/bamtools/src/api/internal/BamRandomAccessController_p.h +93 -0
- data/ext/bamtools/src/api/internal/BamReader_p.cpp +380 -0
- data/ext/bamtools/src/api/internal/BamReader_p.h +112 -0
- data/ext/bamtools/src/api/internal/BamStandardIndex_p.cpp +986 -0
- data/ext/bamtools/src/api/internal/BamStandardIndex_p.h +236 -0
- data/ext/bamtools/src/api/internal/BamToolsIndex_p.cpp +641 -0
- data/ext/bamtools/src/api/internal/BamToolsIndex_p.h +187 -0
- data/ext/bamtools/src/api/internal/BamWriter_p.cpp +424 -0
- data/ext/bamtools/src/api/internal/BamWriter_p.h +66 -0
- data/ext/bamtools/src/api/internal/BgzfStream_p.cpp +438 -0
- data/ext/bamtools/src/api/internal/BgzfStream_p.h +108 -0
- data/ext/bamtools/src/api/internal/SamFormatParser_p.cpp +230 -0
- data/ext/bamtools/src/api/internal/SamFormatParser_p.h +61 -0
- data/ext/bamtools/src/api/internal/SamFormatPrinter_p.cpp +210 -0
- data/ext/bamtools/src/api/internal/SamFormatPrinter_p.h +60 -0
- data/ext/bamtools/src/api/internal/SamHeaderValidator_p.cpp +510 -0
- data/ext/bamtools/src/api/internal/SamHeaderValidator_p.h +101 -0
- data/ext/bamtools/src/api/internal/SamHeaderVersion_p.h +134 -0
- data/ext/bamtools/src/cmake_install.cmake +42 -0
- data/ext/bamtools/src/shared/bamtools_global.h +78 -0
- data/ext/bamtools/src/third_party/CMakeFiles/CMakeDirectoryInformation.cmake +22 -0
- data/ext/bamtools/src/third_party/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/third_party/CMakeLists.txt +10 -0
- data/ext/bamtools/src/third_party/Makefile +167 -0
- data/ext/bamtools/src/third_party/cmake_install.cmake +35 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/CMakeDirectoryInformation.cmake +22 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/CXX.includecache +144 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/DependInfo.cmake +27 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/build.make +157 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/cmake_clean.cmake +13 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/depend.internal +31 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/depend.make +31 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/flags.make +8 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/json_reader.cpp.o +0 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/json_value.cpp.o +0 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/json_writer.cpp.o +0 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/link.txt +1 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/jsoncpp.dir/progress.make +4 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/third_party/jsoncpp/CMakeLists.txt +23 -0
- data/ext/bamtools/src/third_party/jsoncpp/LICENSE +55 -0
- data/ext/bamtools/src/third_party/jsoncpp/Makefile +263 -0
- data/ext/bamtools/src/third_party/jsoncpp/cmake_install.cmake +29 -0
- data/ext/bamtools/src/third_party/jsoncpp/json.h +15 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_batchallocator.h +130 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_config.h +42 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_features.h +47 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_forwards.h +42 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_internalarray.inl +453 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_internalmap.inl +612 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_reader.cpp +870 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_reader.h +201 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_tool.h +93 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_value.cpp +1701 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_value.h +1059 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_valueiterator.inl +297 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_writer.cpp +819 -0
- data/ext/bamtools/src/third_party/jsoncpp/json_writer.h +179 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/CMakeDirectoryInformation.cmake +25 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/CXX.includecache +698 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/DependInfo.cmake +34 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_convert.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_count.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_coverage.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_filter.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_header.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_index.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_merge.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_random.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_resolve.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_revert.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_sort.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_split.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/bamtools_stats.cpp.o +0 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/build.make +447 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/cmake_clean.cmake +24 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/depend.internal +319 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/depend.make +319 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/flags.make +8 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/link.txt +1 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/bamtools_cmd.dir/progress.make +15 -0
- data/ext/bamtools/src/toolkit/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/toolkit/CMakeLists.txt +44 -0
- data/ext/bamtools/src/toolkit/Makefile +560 -0
- data/ext/bamtools/src/toolkit/bamtools.cpp +163 -0
- data/ext/bamtools/src/toolkit/bamtools_convert.cpp +888 -0
- data/ext/bamtools/src/toolkit/bamtools_convert.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_count.cpp +187 -0
- data/ext/bamtools/src/toolkit/bamtools_count.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_coverage.cpp +196 -0
- data/ext/bamtools/src/toolkit/bamtools_coverage.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_filter.cpp +911 -0
- data/ext/bamtools/src/toolkit/bamtools_filter.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_header.cpp +122 -0
- data/ext/bamtools/src/toolkit/bamtools_header.h +38 -0
- data/ext/bamtools/src/toolkit/bamtools_index.cpp +126 -0
- data/ext/bamtools/src/toolkit/bamtools_index.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_merge.cpp +221 -0
- data/ext/bamtools/src/toolkit/bamtools_merge.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_random.cpp +255 -0
- data/ext/bamtools/src/toolkit/bamtools_random.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_resolve.cpp +1396 -0
- data/ext/bamtools/src/toolkit/bamtools_resolve.h +42 -0
- data/ext/bamtools/src/toolkit/bamtools_revert.cpp +194 -0
- data/ext/bamtools/src/toolkit/bamtools_revert.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_sort.cpp +410 -0
- data/ext/bamtools/src/toolkit/bamtools_sort.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_split.cpp +551 -0
- data/ext/bamtools/src/toolkit/bamtools_split.h +38 -0
- data/ext/bamtools/src/toolkit/bamtools_stats.cpp +286 -0
- data/ext/bamtools/src/toolkit/bamtools_stats.h +37 -0
- data/ext/bamtools/src/toolkit/bamtools_tool.h +35 -0
- data/ext/bamtools/src/toolkit/bamtools_version.h +20 -0
- data/ext/bamtools/src/toolkit/bamtools_version.h.in +20 -0
- data/ext/bamtools/src/toolkit/cmake_install.cmake +52 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/CXX.includecache +250 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/DependInfo.cmake +29 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/bamtools_fasta.cpp.o +0 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/bamtools_options.cpp.o +0 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/bamtools_pileup_engine.cpp.o +0 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/bamtools_utilities.cpp.o +0 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/build.make +184 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/cmake_clean.cmake +14 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/depend.internal +40 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/depend.make +40 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/flags.make +8 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/link.txt +1 -0
- data/ext/bamtools/src/utils/CMakeFiles/BamTools-utils.dir/progress.make +5 -0
- data/ext/bamtools/src/utils/CMakeFiles/CMakeDirectoryInformation.cmake +23 -0
- data/ext/bamtools/src/utils/CMakeFiles/progress.marks +1 -0
- data/ext/bamtools/src/utils/CMakeLists.txt +30 -0
- data/ext/bamtools/src/utils/Makefile +290 -0
- data/ext/bamtools/src/utils/bamtools_fasta.cpp +632 -0
- data/ext/bamtools/src/utils/bamtools_fasta.h +47 -0
- data/ext/bamtools/src/utils/bamtools_filter_engine.h +552 -0
- data/ext/bamtools/src/utils/bamtools_filter_properties.h +195 -0
- data/ext/bamtools/src/utils/bamtools_filter_ruleparser.h +319 -0
- data/ext/bamtools/src/utils/bamtools_options.cpp +287 -0
- data/ext/bamtools/src/utils/bamtools_options.h +213 -0
- data/ext/bamtools/src/utils/bamtools_pileup_engine.cpp +327 -0
- data/ext/bamtools/src/utils/bamtools_pileup_engine.h +94 -0
- data/ext/bamtools/src/utils/bamtools_utilities.cpp +333 -0
- data/ext/bamtools/src/utils/bamtools_utilities.h +67 -0
- data/ext/bamtools/src/utils/bamtools_variant.h +128 -0
- data/ext/bamtools/src/utils/cmake_install.cmake +29 -0
- data/ext/bamtools/src/utils/utils_global.h +21 -0
- data/lib/ngs_server/version.rb +3 -0
- data/lib/ngs_server.rb +3 -0
- data/ngs_server.gemspec +23 -0
- metadata +339 -0
@@ -0,0 +1,255 @@
|
|
1
|
+
// ***************************************************************************
|
2
|
+
// bamtools_random.cpp (c) 2010 Derek Barnett, Erik Garrison
|
3
|
+
// Marth Lab, Department of Biology, Boston College
|
4
|
+
// ---------------------------------------------------------------------------
|
5
|
+
// Last modified: 7 April 2011 (DB)
|
6
|
+
// ---------------------------------------------------------------------------
|
7
|
+
// Grab a random subset of alignments (testing tool)
|
8
|
+
// ***************************************************************************
|
9
|
+
|
10
|
+
#include "bamtools_random.h"
|
11
|
+
|
12
|
+
#include <api/BamMultiReader.h>
|
13
|
+
#include <api/BamWriter.h>
|
14
|
+
#include <utils/bamtools_options.h>
|
15
|
+
#include <utils/bamtools_utilities.h>
|
16
|
+
using namespace BamTools;
|
17
|
+
|
18
|
+
#include <ctime>
|
19
|
+
#include <cstdlib>
|
20
|
+
#include <iostream>
|
21
|
+
#include <string>
|
22
|
+
#include <vector>
|
23
|
+
using namespace std;
|
24
|
+
|
25
|
+
namespace BamTools {
|
26
|
+
|
27
|
+
// define constants
|
28
|
+
const unsigned int RANDOM_MAX_ALIGNMENT_COUNT = 10000;
|
29
|
+
|
30
|
+
// utility methods for RandomTool
|
31
|
+
int getRandomInt(const int& lowerBound, const int& upperBound) {
|
32
|
+
const int range = (upperBound - lowerBound) + 1;
|
33
|
+
return ( lowerBound + (int)(range * (double)rand()/((double)RAND_MAX + 1)) );
|
34
|
+
}
|
35
|
+
|
36
|
+
} // namespace BamTools
|
37
|
+
|
38
|
+
// ---------------------------------------------
|
39
|
+
// RandomSettings implementation
|
40
|
+
|
41
|
+
struct RandomTool::RandomSettings {
|
42
|
+
|
43
|
+
// flags
|
44
|
+
bool HasAlignmentCount;
|
45
|
+
bool HasInput;
|
46
|
+
bool HasOutput;
|
47
|
+
bool HasRegion;
|
48
|
+
bool IsForceCompression;
|
49
|
+
|
50
|
+
// parameters
|
51
|
+
unsigned int AlignmentCount;
|
52
|
+
vector<string> InputFiles;
|
53
|
+
string OutputFilename;
|
54
|
+
string Region;
|
55
|
+
|
56
|
+
// constructor
|
57
|
+
RandomSettings(void)
|
58
|
+
: HasAlignmentCount(false)
|
59
|
+
, HasInput(false)
|
60
|
+
, HasOutput(false)
|
61
|
+
, HasRegion(false)
|
62
|
+
, IsForceCompression(false)
|
63
|
+
, AlignmentCount(RANDOM_MAX_ALIGNMENT_COUNT)
|
64
|
+
, OutputFilename(Options::StandardOut())
|
65
|
+
{ }
|
66
|
+
};
|
67
|
+
|
68
|
+
// ---------------------------------------------
|
69
|
+
// RandomToolPrivate implementation
|
70
|
+
|
71
|
+
struct RandomTool::RandomToolPrivate {
|
72
|
+
|
73
|
+
// ctor & dtor
|
74
|
+
public:
|
75
|
+
RandomToolPrivate(RandomTool::RandomSettings* settings)
|
76
|
+
: m_settings(settings)
|
77
|
+
{ }
|
78
|
+
|
79
|
+
~RandomToolPrivate(void) { }
|
80
|
+
|
81
|
+
// interface
|
82
|
+
public:
|
83
|
+
bool Run(void);
|
84
|
+
|
85
|
+
// data members
|
86
|
+
private:
|
87
|
+
RandomTool::RandomSettings* m_settings;
|
88
|
+
};
|
89
|
+
|
90
|
+
bool RandomTool::RandomToolPrivate::Run(void) {
|
91
|
+
|
92
|
+
// set to default stdin if no input files provided
|
93
|
+
if ( !m_settings->HasInput )
|
94
|
+
m_settings->InputFiles.push_back(Options::StandardIn());
|
95
|
+
|
96
|
+
// open our reader
|
97
|
+
BamMultiReader reader;
|
98
|
+
if ( !reader.Open(m_settings->InputFiles) ) {
|
99
|
+
cerr << "bamtools random ERROR: could not open input BAM file(s)... Aborting." << endl;
|
100
|
+
return false;
|
101
|
+
}
|
102
|
+
|
103
|
+
// look up index files for all BAM files
|
104
|
+
reader.LocateIndexes();
|
105
|
+
|
106
|
+
// make sure index data is available
|
107
|
+
if ( !reader.HasIndexes() ) {
|
108
|
+
cerr << "bamtools random ERROR: could not load index data for all input BAM file(s)... Aborting." << endl;
|
109
|
+
reader.Close();
|
110
|
+
return false;
|
111
|
+
}
|
112
|
+
|
113
|
+
// get BamReader metadata
|
114
|
+
const string headerText = reader.GetHeaderText();
|
115
|
+
const RefVector references = reader.GetReferenceData();
|
116
|
+
if ( references.empty() ) {
|
117
|
+
cerr << "bamtools random ERROR: no reference data available... Aborting." << endl;
|
118
|
+
reader.Close();
|
119
|
+
return false;
|
120
|
+
}
|
121
|
+
|
122
|
+
// determine compression mode for BamWriter
|
123
|
+
bool writeUncompressed = ( m_settings->OutputFilename == Options::StandardOut() &&
|
124
|
+
!m_settings->IsForceCompression );
|
125
|
+
BamWriter::CompressionMode compressionMode = BamWriter::Compressed;
|
126
|
+
if ( writeUncompressed ) compressionMode = BamWriter::Uncompressed;
|
127
|
+
|
128
|
+
// open BamWriter
|
129
|
+
BamWriter writer;
|
130
|
+
writer.SetCompressionMode(compressionMode);
|
131
|
+
if ( !writer.Open(m_settings->OutputFilename, headerText, references) ) {
|
132
|
+
cerr << "bamtools random ERROR: could not open " << m_settings->OutputFilename
|
133
|
+
<< " for writing... Aborting." << endl;
|
134
|
+
reader.Close();
|
135
|
+
return false;
|
136
|
+
}
|
137
|
+
|
138
|
+
// if user specified a REGION constraint, attempt to parse REGION string
|
139
|
+
BamRegion region;
|
140
|
+
if ( m_settings->HasRegion && !Utilities::ParseRegionString(m_settings->Region, reader, region) ) {
|
141
|
+
cerr << "bamtools random ERROR: could not parse REGION: " << m_settings->Region << endl;
|
142
|
+
cerr << "Check that REGION is in valid format (see documentation) and that the coordinates are valid"
|
143
|
+
<< endl;
|
144
|
+
reader.Close();
|
145
|
+
writer.Close();
|
146
|
+
return false;
|
147
|
+
}
|
148
|
+
|
149
|
+
// seed our random number generator
|
150
|
+
srand( time(NULL) );
|
151
|
+
|
152
|
+
// grab random alignments
|
153
|
+
BamAlignment al;
|
154
|
+
unsigned int i = 0;
|
155
|
+
while ( i < m_settings->AlignmentCount ) {
|
156
|
+
|
157
|
+
int randomRefId = 0;
|
158
|
+
int randomPosition = 0;
|
159
|
+
|
160
|
+
// use REGION constraints to select random refId & position
|
161
|
+
if ( m_settings->HasRegion ) {
|
162
|
+
|
163
|
+
// select a random refId
|
164
|
+
randomRefId = getRandomInt(region.LeftRefID, region.RightRefID);
|
165
|
+
|
166
|
+
// select a random position based on randomRefId
|
167
|
+
const int lowerBoundPosition = ( (randomRefId == region.LeftRefID)
|
168
|
+
? region.LeftPosition
|
169
|
+
: 0 );
|
170
|
+
const int upperBoundPosition = ( (randomRefId == region.RightRefID)
|
171
|
+
? region.RightPosition
|
172
|
+
: (references.at(randomRefId).RefLength - 1) );
|
173
|
+
randomPosition = getRandomInt(lowerBoundPosition, upperBoundPosition);
|
174
|
+
}
|
175
|
+
|
176
|
+
// otherwise select from all possible random refId & position
|
177
|
+
else {
|
178
|
+
|
179
|
+
// select random refId
|
180
|
+
randomRefId = getRandomInt(0, (int)references.size() - 1);
|
181
|
+
|
182
|
+
// select random position based on randomRefId
|
183
|
+
const int lowerBoundPosition = 0;
|
184
|
+
const int upperBoundPosition = references.at(randomRefId).RefLength - 1;
|
185
|
+
randomPosition = getRandomInt(lowerBoundPosition, upperBoundPosition);
|
186
|
+
}
|
187
|
+
|
188
|
+
// if jump & read successful, save first alignment that overlaps random refId & position
|
189
|
+
if ( reader.Jump(randomRefId, randomPosition) ) {
|
190
|
+
while ( reader.GetNextAlignmentCore(al) ) {
|
191
|
+
if ( al.RefID == randomRefId && al.Position >= randomPosition ) {
|
192
|
+
writer.SaveAlignment(al);
|
193
|
+
++i;
|
194
|
+
break;
|
195
|
+
}
|
196
|
+
}
|
197
|
+
}
|
198
|
+
}
|
199
|
+
|
200
|
+
// cleanup & exit
|
201
|
+
reader.Close();
|
202
|
+
writer.Close();
|
203
|
+
return true;
|
204
|
+
}
|
205
|
+
|
206
|
+
// ---------------------------------------------
|
207
|
+
// RandomTool implementation
|
208
|
+
|
209
|
+
RandomTool::RandomTool(void)
|
210
|
+
: AbstractTool()
|
211
|
+
, m_settings(new RandomSettings)
|
212
|
+
, m_impl(0)
|
213
|
+
{
|
214
|
+
// set program details
|
215
|
+
Options::SetProgramInfo("bamtools random", "grab a random subset of alignments", "[-in <filename> -in <filename> ...] [-out <filename>] [-forceCompression] [-n] [-region <REGION>]");
|
216
|
+
|
217
|
+
// set up options
|
218
|
+
OptionGroup* IO_Opts = Options::CreateOptionGroup("Input & Output");
|
219
|
+
Options::AddValueOption("-in", "BAM filename", "the input BAM file", "", m_settings->HasInput, m_settings->InputFiles, IO_Opts, Options::StandardIn());
|
220
|
+
Options::AddValueOption("-out", "BAM filename", "the output BAM file", "", m_settings->HasOutput, m_settings->OutputFilename, IO_Opts, Options::StandardOut());
|
221
|
+
Options::AddOption("-forceCompression", "if results are sent to stdout (like when piping to another tool), default behavior is to leave output uncompressed. Use this flag to override and force compression", m_settings->IsForceCompression, IO_Opts);
|
222
|
+
Options::AddValueOption("-region", "REGION", "only pull random alignments from within this genomic region. Index file is recommended for better performance, and is used automatically if it exists. See \'bamtools help index\' for more details on creating one", "", m_settings->HasRegion, m_settings->Region, IO_Opts);
|
223
|
+
|
224
|
+
OptionGroup* SettingsOpts = Options::CreateOptionGroup("Settings");
|
225
|
+
Options::AddValueOption("-n", "count", "number of alignments to grab. Note - no duplicate checking is performed", "", m_settings->HasAlignmentCount, m_settings->AlignmentCount, SettingsOpts, RANDOM_MAX_ALIGNMENT_COUNT);
|
226
|
+
}
|
227
|
+
|
228
|
+
RandomTool::~RandomTool(void) {
|
229
|
+
|
230
|
+
delete m_settings;
|
231
|
+
m_settings = 0;
|
232
|
+
|
233
|
+
delete m_impl;
|
234
|
+
m_impl = 0;
|
235
|
+
}
|
236
|
+
|
237
|
+
int RandomTool::Help(void) {
|
238
|
+
Options::DisplayHelp();
|
239
|
+
return 0;
|
240
|
+
}
|
241
|
+
|
242
|
+
int RandomTool::Run(int argc, char* argv[]) {
|
243
|
+
|
244
|
+
// parse command line arguments
|
245
|
+
Options::Parse(argc, argv, 1);
|
246
|
+
|
247
|
+
// initialize RandomTool with settings
|
248
|
+
m_impl = new RandomToolPrivate(m_settings);
|
249
|
+
|
250
|
+
// run RandomTool, return success/fail
|
251
|
+
if ( m_impl->Run() )
|
252
|
+
return 0;
|
253
|
+
else
|
254
|
+
return 1;
|
255
|
+
}
|
@@ -0,0 +1,37 @@
|
|
1
|
+
// ***************************************************************************
|
2
|
+
// bamtools_random.h (c) 2010 Derek Barnett, Erik Garrison
|
3
|
+
// Marth Lab, Department of Biology, Boston College
|
4
|
+
// ---------------------------------------------------------------------------
|
5
|
+
// Last modified: 7 April 2010 (DB)
|
6
|
+
// ---------------------------------------------------------------------------
|
7
|
+
// Grab a random subset of alignments (testing tool)
|
8
|
+
// ***************************************************************************
|
9
|
+
|
10
|
+
#ifndef BAMTOOLS_RANDOM_H
|
11
|
+
#define BAMTOOLS_RANDOM_H
|
12
|
+
|
13
|
+
#include "bamtools_tool.h"
|
14
|
+
|
15
|
+
namespace BamTools {
|
16
|
+
|
17
|
+
class RandomTool : public AbstractTool {
|
18
|
+
|
19
|
+
public:
|
20
|
+
RandomTool(void);
|
21
|
+
~RandomTool(void);
|
22
|
+
|
23
|
+
public:
|
24
|
+
int Help(void);
|
25
|
+
int Run(int argc, char* argv[]);
|
26
|
+
|
27
|
+
private:
|
28
|
+
struct RandomSettings;
|
29
|
+
RandomSettings* m_settings;
|
30
|
+
|
31
|
+
struct RandomToolPrivate;
|
32
|
+
RandomToolPrivate* m_impl;
|
33
|
+
};
|
34
|
+
|
35
|
+
} // namespace BamTools
|
36
|
+
|
37
|
+
#endif // BAMTOOLS_RANDOM _H
|