IPCA basis ims can now deal with a variable number of basis images, but does not yet adjust to changes in number. for now magic 2 still hard-coded