Added skeleton for learnOnSegments