A new way of using artificial intelligence to predict cancer from patient data without putting personal information at risk has been developed. Swarm learning can be used to help computers predict cancer in medical images of patient tissue samples, without releasing the data from hospitals.