Training recursive neural networks