ICSM / ampere

A tool to fit the SED and spectra of dusty objects to constrain, among other things, the dust properties and mineralogy
6 stars 2 forks source link

implement covariance matrix population #5

Closed pscicluna closed 6 years ago

pscicluna commented 6 years ago

This is the real meat of ampere, and so has to be done right. We need a general way of populating the covariance matrices for each kind of data and a way of getting the optimiser to understand how the parameters it is given relate to this. It will also need some optimisation as we want the matrices to be as sparse as possible for computational efficiency, so we may have to come up with truncation criteria or ways of chunking the matrices (e.g. splitting the data into blocks, with lower-resolution interactions with more distant data blocks).

pscicluna commented 6 years ago

I am currently implementing a very simple version, exclusively for spectra for the moment - the covariance matrix is modelled as the linear combination of an uncorrelated component (i.e. a diagonal matrix) and a single Gaussian component (i.e. rho_ij = exp( -(i - j)**2 / (2*d**2)), where d is a free parameter controlling the scale-length of the correlations). The two components are weighted such that the sum of the weights = 1, and is truncated for small values of rho_ij to try to improve computational efficiency. Tests are ongoing, but it appears to work so far!

pscicluna commented 6 years ago

First test fitting photometry and spectra were successful. More complex tests required, but I think we'll be ready to do some actual science quite soon!

pscicluna commented 6 years ago

This seems to work in the very basic sense for real data. I'm going to close this and we can open more issues with more specific cases of what needs to be added. This means we can get ready to tag a v0.1.