Accounting for diversity in AI for medicine