Tried to optimize second_window function. Used a deque for the sliding window in which we're calculating the min and max. Used np.ndarray.item to read more efficiently an item from a numpy array, and np.ma.put to write more efficiently to a numpy masked array. No need in the loop to check for masked data, as we are working on unmasked slices anyway.
Tried to optimize second_window function. Used a deque for the sliding window in which we're calculating the min and max. Used np.ndarray.item to read more efficiently an item from a numpy array, and np.ma.put to write more efficiently to a numpy masked array. No need in the loop to check for masked data, as we are working on unmasked slices anyway.
Un-commented the return statement.
Try to optimize second_window.
In second_window, removed any reference to start or stop. Added some comments.
Merged from origin/second_window_optimize
Applied again clump_unmasked function to the array. This is necessary to correctly ignore any masked data.
Improved performances of second_window.
Added A330 overflow correction test for 8191
Merge branch 'second_window_optimize' of
https://github.com/dangillet/FlightDataAnalyzer into dangillet-second_window_optimize

Conflicts:
	analysis_engine/library.py
Fixed second_window test to reflect refactoring.
Merge branch 'master' of
https://github.com/FlightDataServices/FlightDataAnalyzer