localizations data is either available in LocationHypothesis or SourcesAzimuthsDistributionHypothesis objects depending on which KS wrote the data to the blackboard.
StreamSegregation will try to use the polished LocationHypothesis data and will resort to the data stored as SourcesAzimuthsDistributionHypothesis if the former is not available.
Both Hypthesis classes don't share the exact attribute names, therefore several isfield() calls are made to access the correct properties. This PR replaces the isfield calls with checking a flag that is set, once it is determined which hypothesis class will be used.
Why do we need this? For some reason the isfield method returns false even though the property is available and accessible. I don't know why it wouldn't work in this particular case, but this avoids this odd behavior altogether.
localizations data is either available in
LocationHypothesis
orSourcesAzimuthsDistributionHypothesis
objects depending on which KS wrote the data to the blackboard. StreamSegregation will try to use the polishedLocationHypothesis
data and will resort to the data stored asSourcesAzimuthsDistributionHypothesis
if the former is not available.Both Hypthesis classes don't share the exact attribute names, therefore several isfield() calls are made to access the correct properties. This PR replaces the isfield calls with checking a flag that is set, once it is determined which hypothesis class will be used.
Why do we need this? For some reason the isfield method returns false even though the property is available and accessible. I don't know why it wouldn't work in this particular case, but this avoids this odd behavior altogether.