IndexedFilteredEssFieldWrapper¶
- class lsst.ts.watcher.IndexedFilteredEssFieldWrapper(model, topic, sensor_name, field_name, indices)¶
Bases:
FilteredEssFieldWrapper
A filtered field wrapper for an array field, with metadata indicating indices of interest.
FieldWrapperList
provides 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 the
sensorName
field.- 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; the
value
attribute contains all elements, just likeFilteredEssFieldWrapper
.
- model
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.
Methods Summary
get_value_descr
(index)Get a description for a value.
update_value
(data)Set
value
from DDS data.Methods Documentation
- get_value_descr(index)¶
Get a description for a value.
- update_value(data)¶
Set
value
from DDS data.Do not set the
timestamp
field, and do not check thatgetattr(data, filter_field) == self.filter_value
; both of these are done by the caller:FilteredTopicWrapper.__call__
.