Neural approximations of the solutions to a class of stochastic optimal control problems