MedianGradientAction

class lsst.analysis.tools.actions.scalar.MedianGradientAction(*args, **kw)

Bases: ScalarAction

Calculate the gradient of a running median

Attributes Summary

lowerBinLimit

Percentile of data to start the bining at (float, default 5.0)

nBins

Number of bins to use for running median (int, default 50)

upperBinLimit

Percentile of data to end the binning at (float, default 95.0)

xsVectorKey

Key of Vector that gives the x location of the points.

ysVectorKey

Key of the Vector to compute the statistic from.

Methods Summary

__call__(data, **kwargs)

Return the gradient of the running median.

getInputSchema()

Return the schema an AnalysisAction expects to be present in the arguments supplied to the __call__ method.

Attributes Documentation

lowerBinLimit

Percentile of data to start the bining at (float, default 5.0)

nBins

Number of bins to use for running median (int, default 50)

upperBinLimit

Percentile of data to end the binning at (float, default 95.0)

xsVectorKey

Key of Vector that gives the x location of the points. (str)

ysVectorKey

Key of the Vector to compute the statistic from. (str)

Methods Documentation

__call__(data: MutableMapping[str, ndarray[tuple[Any, ...], dtype[_ScalarT]] | Scalar | HealSparseMap | Tensor | Mapping], **kwargs) Scalar

Return the gradient of the running median.

Parameters:
dataKeyedData
Returns:
resultScalar

The gradient of the running median

getInputSchema() Iterable[tuple[str, type[numpy.ndarray[tuple[Any, ...], numpy.dtype[_ScalarT]]] | type[lsst.analysis.tools.interfaces._interfaces.Scalar] | type[healsparse.healSparseMap.HealSparseMap] | type[lsst.analysis.tools.interfaces._interfaces.Tensor] | type[collections.abc.Mapping]]]

Return the schema an AnalysisAction expects to be present in the arguments supplied to the __call__ method.

Returns:
resultKeyedDataSchema

The schema this action requires to be present when calling this action, keys are unformatted.