Skip to content

Commit

Permalink
Check whether op is applied before skipping
Browse files Browse the repository at this point in the history
  • Loading branch information
felixhekhorn authored and cschwan committed Jul 3, 2022
1 parent 9d77950 commit 655feb1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pineappl/src/grid.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1675,12 +1675,12 @@ impl Grid {

// if `op1` and `op2` below are zero there's no work to do
// TODO: ideally we change the for loops instead of vetoing here
if !non_zero_pid_indices
if (has_pdf1 && !non_zero_pid_indices
.iter()
.any(|&tuple| tuple == (tgt_pid1_idx, src_pid1_idx))
|| !non_zero_pid_indices
.any(|&tuple| tuple == (tgt_pid1_idx, src_pid1_idx)))
|| (has_pdf2 && !non_zero_pid_indices
.iter()
.any(|&tuple| tuple == (tgt_pid2_idx, src_pid2_idx))
.any(|&tuple| tuple == (tgt_pid2_idx, src_pid2_idx)))
{
continue;
}
Expand Down

0 comments on commit 655feb1

Please sign in to comment.