Computation of optimal transport and related hedging problems via penalization and neural networks