Team work at Masters level
As scaaahu commented: This happens ALL the time in industry (one could say it is the rule, not the exception). We do not always get to pick our teams and it is common for high-performers to be stuck with those who do not really care about the quality of their work. Will someone get fired in industry? Maybe...maybe not (complex issue).

The thing you must understand is the difference between management, where someone has formal authority based on their position in the organization, and leadership, where someone's authority basically comes from the followers.

If your team is fill with under-performers you need to figure out if you can use some leadership skills to motivate them to do better. This is the same when studying and when working. If you cannot motivate them then you must decide if someone else can (perhaps you need to encourage someone else to act as the leader). If it seems the team simply cannot be motivated, then you should do your best to find another team.

A team can only be successful if the team feels like a team and that means, in part, that everyone believes in the same goal and are willing to sacrifice to achieve that goal.

The solution is to develop some leadership skills and have a direct talk with the team about what they hope to achieve.