BellaNasirudin / py21cmmc_fg

A foreground and instrumental plugin for py21cmmc
MIT License
1 stars 4 forks source link

proper way to sum weights #12

Closed steven-murray closed 6 years ago

steven-murray commented 6 years ago

How should the weights be calculated after fourier transforming along the frequency axis? Are they merely summed? Or summed with a weight given by the taper? Or something else?

steven-murray commented 6 years ago

From our discussion today, we need to treat the weights as stand-ins for variance (they are indicative of the variance of each of the statistically-equivalent baselines). Therefore, if the signal itself is transformed with a taper, then the total variance is summed with that same taper.

I'll put this in with the taper.

steven-murray commented 6 years ago

fixed in 13424f073f97de1faa498ad7988ba50a4b5bf3d4. Note that summing like this means that the weights are effectively a 2D array, rather than 3D, which means that angular_average_nd can be used directly, simplifying code considerably.