Is there a method to recalculate normals for geometry deformed with WPO, on a section of a Vertex paint mask?

I have an understanding of the methods and ways this can be done within UV coordinates, or using a texture mask for various cases, but it is not clear if there is a way to do this using a vertex paint mask. Let’s imagine that we have drawn a circle on a plane using Vertex Paint. This circle is extruded by WPO to some height, and for correct shading we need to get updated surface normals. For a better understanding of the issue I can give an example of height painting in Substance painter, where the resulting mask is eventually converted into a normal map. The option with ddx and ddy does not suit me (as well as already available in UE material functions based on the same ddx and ddy, as they do not provide normals in a smoothed form). I will be glad to hear any options for solving this problem, including code. Also at this stage I am not very concerned about performance, I am interested in finding a solution, no matter how costly it may be.