Shepherding algorithm for heterogeneous flock with model-based discrimination. (17th January 2023)