Not a doctor but there will be more to unpicking the data than this.
QUB is a case in point. It has a good reputation for teaching in quite a traditional manner. Numbers of international students are capped and NI students don't get grants to study elsewhere in the UK. So a high proportion of NI students, presumably representing the full range including those who have excelled in NIs well regarded secondary schools. Many will stay in the Province for F1/F2 and want to continue their careers there.
Health is devolved, so different parts of the UK have different F1/F2 contracts. England has an updated one with fewer hours, more support and dedicated time for personal development. NI still uses the old 2005 one, and unlike some English NHS Trusts it is night shifts from day one. From posts on this thread, the latter should be an advantage. More real hands experience is arguably what , doctors setting out need.
Unfortunately immigration policy is not devolved, nor is much of the selection for Specialist training. So the young doctor in NI who is working 60 hour weeks in busy hospitals (and the health service there really is under siege) is having to compete for training against students from overseas who may have been able to access two years of private college to gain advance qualifications and support for CV enhancing (and points gaining) accomplishments. If the selection process included scoring that took into account appraisals or references it might well be a different matter. Similarly it is difficult to compete with overseas agency supported staff for F3 style vacancies which would allow them more time to prepare. Frustratingly then the no show rate seems quite high and the retention rate low, so NI is left with vacancies at F3 level and all the way through the training path, exacerbating some shockingly long waiting lists. Consultants clearly find it frustrating that they are having to cover for staff shortages whilst writing references for good F2s who are having to go overseas to find work.
(This shows up the the stats Marchesman provided. Even in 2023 the number of doctors in NI who are in their 20s is falling. This statistic can be expected to rise as the problem becomes more acute. Overseas doctors appointed to F3 type positions tend to have more experience and be older.)
It would be unwise to use headline statistics to suggest that QUB is the weakest medical school. And indeed I don't think trying to identify the "best" medical school is particularly helpful. It is often about best fit, and perhaps acknowledging that some will attract the most ambitious and determined. So courses are five, others are six, but some of those on a five year course will have intercalated for a year.
There are also very different jobs. One of DDs friends has found a temporary cover role in geriatrics. Mainly assessing for discharge which needs a doctor and presumably being on hand in case of an emergency. She is ambitious and the slow pace does not suit her at all, but perhaps suits someone who wants a local regular hours job. In the same way that not all teachers want to become heads. Focussing on training high flying potential academic consultants when there are plenty of jobs that don't require as much (and may require other strengths including softer or organisational skills) would be silly. And I really don't understand this concern about weaker medical schools when rather than recruit our own we are bringing in large numbers from overseas, some who have taken alternative exams with higher pass rates, and despite plenty of anecdotal evidence, and indeed metrics such as the number of upheld complaints, that suggests that medical education in the weakest of overseas medical schools is not better than the weakest of ours.