The spiked matrix model with generative priors