Skip to content

Commit

Permalink
Fix mask for fiducial model
Browse files Browse the repository at this point in the history
  • Loading branch information
andreicuceu committed Nov 26, 2023
1 parent fbf6532 commit 27cb9e4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vega/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,8 @@ def create_monte_carlo(self, fiducial_model, scale=None, seed=None, forecast=Fal
self.mc_mock = np.full(self.full_data_size, np.nan)

Check warning on line 601 in vega/data.py

View check run for this annotation

Codecov / codecov/patch

vega/data.py#L601

Added line #L601 was not covered by tests
if self.cholesky_masked_cov:
ran_vec = np.random.randn(self.data_mask.sum())
self.mc_mock[self.data_mask] = masked_fiducial + self._cholesky.dot(ran_vec)
self.mc_mock[self.data_mask] = \

Check warning on line 604 in vega/data.py

View check run for this annotation

Codecov / codecov/patch

vega/data.py#L603-L604

Added lines #L603 - L604 were not covered by tests
masked_fiducial[self.data_mask] + self._cholesky.dot(ran_vec)
else:
ran_vec = np.random.randn(self.full_data_size)
self.mc_mock = masked_fiducial + self._cholesky.dot(ran_vec)

Check warning on line 608 in vega/data.py

View check run for this annotation

Codecov / codecov/patch

vega/data.py#L607-L608

Added lines #L607 - L608 were not covered by tests
Expand Down

0 comments on commit 27cb9e4

Please sign in to comment.