Skip to content

correlated covmats from lists of commondata

Created by: wilsonmr

I think that this method is easier to understand, in theory the split systematics could also split into multiplicative and additive systematics which might be useful for generating the pseudodata. The special experimental systematics are correlated by using the systematics names as columns and concatenating a dataframe. The rest only contribute to block diagonals anyway.

note that this implicitly handles the empty cases because:

>>> a = np.empty((34, 0))
>>> a
array([], shape=(34, 0), dtype=float64)
>>> a @ a.T
array([[0., 0., 0., ..., 0., 0., 0.],
       [0., 0., 0., ..., 0., 0., 0.],
       [0., 0., 0., ..., 0., 0., 0.],
       ...,
       [0., 0., 0., ..., 0., 0., 0.],
       [0., 0., 0., ..., 0., 0., 0.],
       [0., 0., 0., ..., 0., 0., 0.]])
>>> (a**2).sum(axis=1)
array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
       0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.])

Since it's a rather large change I thought a PR might be more appropriate.

Let me know what you think. It probs needs better docs and reformatting but you get the idea. I shortened considerably the docs of constructing the covmat because I think having a dump of the old c++ code is a bit much..

Merge request reports

Loading