Browse Source

fix segment_map -> segment (#556)

pull/1/head
Evgeny Smyshlyaev 6 years ago committed by Alexey Velikiy
parent
commit
c5e24b5739
  1. 2
      analytics/analytics/models/model.py

2
analytics/analytics/models/model.py

@ -76,7 +76,7 @@ class Model(ABC):
if segment_map['labeled'] or segment_map['deleted']: if segment_map['labeled'] or segment_map['deleted']:
segment = Segment(dataframe, segment_map, self.find_segment_center) segment = Segment(dataframe, segment_map, self.find_segment_center)
if segment.percent_of_nans > 0.1 or len(segment.data) == 0: if segment.percent_of_nans > 0.1 or len(segment.data) == 0:
logging.debug(f'segment {segment_map.start}-{segment_map.end} skip because of invalid data') logging.debug(f'segment {segment.start}-{segment.end} skip because of invalid data')
continue continue
if segment.percent_of_nans > 0: if segment.percent_of_nans > 0:
segment.convert_nan_to_zero() segment.convert_nan_to_zero()

Loading…
Cancel
Save