mt_metadata.features.weights.threshold_weight_kernel ==================================================== .. py:module:: mt_metadata.features.weights.threshold_weight_kernel Classes ------- .. autoapisummary:: mt_metadata.features.weights.threshold_weight_kernel.ThresholdWeightKernel Module Contents --------------- .. py:class:: ThresholdWeightKernel(**data) Bases: :py:obj:`mt_metadata.features.weights.taper_monotonic_weight_kernel.TaperMonotonicWeightKernel` ThresholdWeightKernel A special case of MonotonicWeightKernel where the transition region is a single value, resulting in a hard threshold (step function). This kernel outputs 0 or 1 depending on whether the input is above or below the threshold, according to the threshold_type. :param threshold: The threshold value. :type threshold: float :param threshold_type: "low cut" (default) or "high cut". Determines which side is downweighted. :type threshold_type: str, optional :param \*\*kwargs: Additional keyword arguments passed to MonotonicWeightKernel. .. py:attribute:: threshold_type :type: Annotated[str, Field(default='low cut', description='Which side of a threshold should be downweighted.', alias=None, json_schema_extra={'units': None, 'required': True, 'examples': ['low cut']})]