Computing curvature for volume of fluid methods using machine learning