2.2. empix.annularly_average
- annularly_average(input_signal, optional_params=None)[source]
Average annularly a given input 2D
hyperspysignal.This Python function assumes that the input 2D
hyperspysignal samples from a mathematical function \(F_{\mathbf{m}}\left(u_{x},u_{y}\right)\) which is piecewise continuous in \(u_{x}\) and \(u_{y}\), where \(u_{x}\) and \(u_{y}\) are the horizontal and vertical coordinates in the signal space of the input signal, and \(\mathbf{m}\) is a vector of integers representing the navigation indices of the input signal. The Python function approximates the annular average of \(F_{\mathbf{m}}\left(u_{x},u_{y}\right)\) given the input signal. We define the annular average of \(F_{\mathbf{m}}\left(u_{x},u_{y}\right)\) as(2.2.1)\[\begin{split}&\overline{S}_{\mathbf{m}}\left(u_{r,i}\le U_{r}<u_{r,f} \left|0\le U_{\phi}<2\pi;c_{x},c_{y}\right.\right) \\&\quad=\frac{1}{\pi\left(u_{r,f}^{2}-u_{r,i}^{2}\right)} \int_{u_{r,i}}^{u_{r,f}}du_{r}\,\int_{0}^{2\pi}du_{\phi}\,u_{r} F_{\mathbf{m}}\left(c_{x}+u_{r}\cos\left(u_{\phi}\right), c_{y}+u_{r}\sin\left(u_{\phi}\right)\right),\end{split}\]where \(\left(c_{x},c_{y}\right)\) is the reference point from which the radial distance \(u_r\) is defined for the annular averaging.
- Parameters:
- input_signal
hyperspy._signals.signal2d.Signal2D|hyperspy._signals.complex_signal2d.ComplexSignal2D The input
hyperspysignal.- optional_params
empix.OptionalAnnularAveragingParams| None, optional The set of optional parameters. See the documentation for the class
empix.OptionalAnnularAveragingParamsfor details. Ifoptional_paramsis set toNone, rather than an instance ofempix.OptionalAnnularAveragingParams, then the default values of the optional parameters are chosen.
- input_signal
- Returns:
- output_signal
hyperspy.signal.BaseSignal|hyperspy._signals.complex_signal.ComplexSignal The output
hyperspysignal that samples the annular average of the input signalinput_signal. Note that the metadata of the input signal is copied over to the output signal, with the title being overwritten.
- output_signal