IndexedFilteredEssFieldWrapper#
- class lsst.ts.watcher.IndexedFilteredEssFieldWrapper(model, topic, sensor_name, field_name, indices)#
Bases:
FilteredEssFieldWrapperA filtered field wrapper for an array field, with metadata indicating indices of interest.
FieldWrapperListprovides a useful way to extract the elements of interest.- Parameters:
model (
Model) – Watcher model.topic (
lsst.ts.salobj.ReadTopic) – Topic to read.sensor_name (
str) – Required value of thesensorNamefield.field_name (
str) – Name of field to read. The field must be an array.scalar_descr (
str) – Brief description of the field.indices (
list[int]) – Indices of interest. Negative indices are not supported, so each index must be in range 0 <= index < self.nelts. This is metadata, for use by FieldWrapperList; thevalueattribute contains all elements, just likeFilteredEssFieldWrapper.
Notes
If you specify indices that are not actually connected to sensors then the value will always be nan and so never used. There is no warning because the number of connected sensors is not known when the wrapper is constructed.