The Wasserstein Proximal Gradient Algorithm