Skip to content

Problem with picard CollectHsMetrics - bpipe expecting an output file that was not defined as such #295

@deyanyosifov

Description

@deyanyosifov

I have a very strange problem with the output of picard CollectHsMetrics. bpipe throws an error and the pipeline fails although the output from CollectHsMetrics is as intended. This is my command stage:
HsMetrics = {
output.dir="intermediate_files"
exec """
$PICARD CollectHsMetrics
-I $input.bam
-O $output.bam.prefix
-R $REF
-BAIT_INTERVALS "/data/beds/Probes_merged_ok_combined_ULM_Twist_CLL_2025_1_TE-93654436_hg19.interval_list"
-TARGET_INTERVALS "/data/beds/Target_bases_covered_by_probes_combined_ULM_Twist_CLL_2025_1_TE-93654436_hg19.interval_list"
-PER_TARGET_COVERAGE ${output.bam.prefix}_per_target_coverage.bed"""
}
It takes a whatever.bam file as input and produces two statistics files: whatever.HsMetrics (the main output) and whatever.HsMetrics_per_target_coverage.bed (the optional output defined by the -PER_TARGET_COVERAGE option). I do get the files that I expect, however bpipe throws the error
"ERROR: Expected output file intermediate_files/whatever.HsMetrics.bam in stage HsMetrics could not be found"
and the pipeline fails. Why does it expect to produce a third output file ending in .bam which I have not defined in the command? The problem is not in the optional output, I tried without it and I continue getting the same error. These are the log files: [

211540.bpipe.log
211540.log

](url)

I also tried simply with -I $input -O $output. It still works although the result file is then named whatever.bam.HsMetrics. Not that this is a problem in itself but bpipe still throws an error, this time looking for the output whatever.bam.HsMetrics.bam. Why does bpipe expect a bam file as output when CollectHsMetrics should produce only statistics?

I have never experienced anything similar with other commands including with other commands from the picard package.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions