Hi,
As you guessed, you can only approximate the integral as a sum, not that the integral you are dealing with is also an expectation, so all your formula can be seen as the expectation over X,Y and \delta. In my opinion, you can create a loader over your original dataset, and that yields in addition to X and Y the perturbed X’. Then you can do the rest of the training as usual.
One other thing that seems strange in you case, is that you model $\pi_{\omega}$ seems to be non-deterministic. However I think in practice I think this will be a neural network, so the second expectation on X’ can be ignored, and you can just  compute the loss using the output of   $\pi_{\omega}$.
To summarize, you need to:


Each sample consists of X_{i}, y_{i} and a random $\delta$ generated on the fly, when reading the sample.


When you get a batch of X_{1:B}, y_{1:B} and \delta_{1:B}, you compute X’ = \pi_{\omega}(X+\delta).


You use X’ as your new input to the classification model you are training, i.e., the model labeled with $\theta$, and you compute the first part of the loss as for any classification problem, and you add  the regularization term.