Closed xzackli closed 1 year ago
Merging #52 (ab7e2ca) into master (cca8cf1) will increase coverage by
6.49%
. The diff coverage is93.87%
.
Now validated to float32 numerical precision!
@thibautlouis @zatkins2 this is ready for merge.
I'll let @thibautlouis check the code but I wonder if you can put the fits
file on a server and download them during the unit test ? There are 3 x 26 Mb files and even if we do not change them, it's quite big. Can we imagine a test with smaller files ?
It makes sense to automatically download test data, perhaps tagged as part of a pspy GitHub release. I think astropy has an artifacts system?
I chose the test data here to be very low-resolution pixel variance maps with sufficient resolution to have Nyquist frequency at ell ~ 1350, which is the key scale this PR is trying to target.
I was thinking to something simple such as adding wget
command within the github action script, prior to the test itself.
Of course, it's only 3 x 26 Mb but I don't like the idea that it can cluttered the git history and increase the repository size.
@xgarrido I've moved the test data to be wget in the CI from a tagged release binary blob on my own fork, and force-pushed my fork to erase the history of the large files (you can check here).
looks good to me, perhaps use @ instead of np.dot here ( analytic_cov = np.dot(np.dot(mbb_inv_ab, analytic_cov), mbb_inv_cd.T)) since Xavier has shown that this is faster , once this is done let's merge this !
This PR implements covariance estimation methods from the Planck papers, which have an approximate treatment of noise pixel covariance. They are ported from my Julia code, PowerSpectra.jl. This PR currently implements the only the TTTT covariance, using the Python spin-0 interface to generate the eight coupling matrices involved in this calculation. The polarisation covariances are tedious but straightforward, as long as we have gotten TTTT right.
The agreement between the codes is very good, but there is a 0.01% level difference in the basic coupling matrix calculation that I need help understanding.
The basic inputs are