A method for correcting at least one of pileup effects or charge sharing
effects in multi-cell photon counting detectors includes determining a
correction coefficient using a count rate of an entire spectrum and
applying the determined correction to the counts recorded in an energy
window of interest.