Equivalence between policy gradients and soft Q-learning