Class PerSensorFixedScaler

Per-sensor fixed ranges; each cell maps its own [min,max] to [0..1]. Handles grid resize gracefully:

  • If new count matches arrays → use them directly.
  • If new count differs → broadcasts overall [globalMin, globalMax] to all cells. This means you never crash on channel count changes, just get a less specific scaling.
Inheritance
PerSensorFixedScaler
Implements
Namespace: MOSAIC.Visualization.Heatmap
Assembly: MOSAIC.dll
Syntax
public sealed class PerSensorFixedScaler : IHeatmapScaler

Constructors

PerSensorFixedScaler(double[], double[], double)

Declaration
public PerSensorFixedScaler(double[] mins, double[] maxs, double epsilon = 1E-09)
Parameters
Type Name Description
double[] mins
double[] maxs
double epsilon

Fields

_configuredCount

Declaration
private int _configuredCount
Field Value
Type Description
int

_eps

Declaration
private readonly double _eps
Field Value
Type Description
double

_max

Declaration
private double[] _max
Field Value
Type Description
double[]

_min

Declaration
private double[] _min
Field Value
Type Description
double[]

_overallMax

Declaration
private double _overallMax
Field Value
Type Description
double

_overallMin

Declaration
private double _overallMin
Field Value
Type Description
double

Methods

ComputeOverallBounds()

Declaration
private void ComputeOverallBounds()

Configure(int)

Called whenever the grid size changes (length = rows*cols). Implementations must handle any cell count gracefully — never throw.

Declaration
public void Configure(int cellCount)
Parameters
Type Name Description
int cellCount

MapFrame(ReadOnlySpan<double>, WeightedPoint[], int[]?, Func<double, double>?, out LegendInfo)

Map an input frame to weights in LiveChartsCore.Defaults.WeightedPoint.Weight.

Declaration
public void MapFrame(ReadOnlySpan<double> frame, WeightedPoint[] points, int[]? indexMap, Func<double, double>? valueTransform, out LegendInfo legend)
Parameters
Type Name Description
ReadOnlySpan<double> frame
WeightedPoint[] points
int[] indexMap
Func<double, double> valueTransform
LegendInfo legend

Implements

IHeatmapScaler

Search documentation

Start typing to search the documentation.