Development, optimization, and implementation of a vibration based defect detection algorithm for railroad bearings