A gray-box approach for curriculum learning