A probabilistic autoencoder for causal discovery