code: def centroids(self, instrument, min_abundance=1e-4, points_per_fwhm=25):
          
          assert self.ptr != ffi.NULL
          centroids = ims.spectrum_envelope_centroids(self.ptr, instrument.ptr,
                                                      min_abundance, points_per_fwhm)
          return _new_spectrum(CentroidedSpectrum, centroids)
docs: Estimates centroided peaks for a given instrument model.
  
          :param instrument: instrument model
          :param min_abundance: minimum abundance for including a peak
          :param points_per_fwhm: grid density used for envelope calculation
          :returns: peaks visible with the instrument used
          :rtype: TheoreticalSpectrum