-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Incorporate match consolidation into search (#95)
* Incorporate match consolidation into search * Update consolidation test data
- Loading branch information
Showing
50 changed files
with
604 additions
and
986 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#pragma once | ||
|
||
#include <filesystem> | ||
|
||
#include <valik/shared.hpp> | ||
#include <valik/split/database_metadata.hpp> | ||
|
||
#include <utilities/consolidate/io.hpp> | ||
|
||
namespace valik | ||
{ | ||
|
||
/** | ||
* @brief Function that removes duplicates from split Stellar search results and writes the final output file. | ||
* | ||
* @param arguments Command line arguments. | ||
* @return false If could not clean up intermediate results. | ||
*/ | ||
void consolidate_matches(search_arguments const & arguments); | ||
|
||
} // namespace valik |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#include <utilities/consolidate/consolidate_matches.hpp> | ||
|
||
namespace valik | ||
{ | ||
|
||
void consolidate_matches(search_arguments const & arguments) | ||
{ | ||
auto ref_meta = database_metadata(arguments.ref_meta_path, false); | ||
auto matches = read_stellar_output(arguments.all_matches, ref_meta); | ||
|
||
std::sort( matches.begin(), matches.end(), std::greater<stellar_match>()); | ||
matches.erase( std::unique( matches.begin(), matches.end() ), matches.end() ); | ||
|
||
write_stellar_output(arguments.out_file, matches); | ||
} | ||
|
||
} // namespace valik |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
add_subdirectory(consolidate) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
add_api_test (consolidate_matches_test.cpp) | ||
|
||
target_use_datasources (consolidate_matches_test FILES 8bins50overlap_dream_all.gff) | ||
target_use_datasources (consolidate_matches_test FILES 16bins50overlap_dream_all.gff) | ||
target_use_datasources (consolidate_matches_test FILES 8bins50overlap_reference_metadata.tsv) | ||
target_use_datasources (consolidate_matches_test FILES 16bins50overlap_reference_metadata.tsv) | ||
target_use_datasources (consolidate_matches_test FILES stellar_truth.gff) |
Oops, something went wrong.