-
Notifications
You must be signed in to change notification settings - Fork 370
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Converted VariantCallingMetrics to using mergableMetricsBase #552
Converted VariantCallingMetrics to using mergableMetricsBase #552
Conversation
*/ | ||
public MergeableMetricBase merge(final Collection<? extends MergeableMetricBase> many) { | ||
many.parallelStream().forEach(this::merge); | ||
calculateDerivedFields(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but the merge
below does not call calculateDerivedFields
! please remove.
@yfarjoun rebase onto master and I can revisit. The only comment that requires discussion is the one inside the merging of a collection ( |
f04be0b
to
183e6e7
Compare
@nh13 do you have a few minutes to review this old PR? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few comments, merge when happy.
private static List<Field> getAllFields(Class clazz){ | ||
List<Field> fields = new ArrayList<>(); | ||
fields.addAll(Arrays.asList(clazz.getDeclaredFields())); | ||
Class superClass = clazz.getSuperclass(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
finals?
long numHets, numHomVar; | ||
|
||
public static String getFileExtension() { | ||
return "variant_calling_detail_metrics"; | ||
} | ||
|
||
public static void foldInto(final VariantCallingDetailMetrics target, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be ok to delete instead of deprecate right?
- added tests - extended MergableMetricsBase so that it can deal with private and protected members of the superclass - cleaned up alignment/typos in FilterVcf and MergeBamAlignment (unrelated)
d9faa39
to
92ba5ec
Compare
This fell through the cracks. Did the changes requested, will merge after tests pass. |
This fell through the cracks. Did the changes requested, will merge after tests pass. |
@nh13 you has said that you'd like to see this framework used for something other than IndependentReplicates...so, here's your chance! 😄