Artificial intelligence more accurately diagnosed a possible devastating cause of blindness in premature babies than expert doctors, according to a study.