where \(\mathcal {L}(y,f(x))\)  is formulated as the standard cross-entropy. By \(do\) -operation (causal intervention), we cut off the in-paths to \(X\)  and transform the causal graph in Figure REF  (a) to Figure REF  (b).
Different from traditional empirical risk that samples \((x,y)\)  from \(P(X,Y)\) , we sample \((x,y)\)  from the intervened distribution \(P(do(X),Y)\) . According to the rules of do-calculus [1]}, we have \(P(do(X=x))=P(X=x)\) . Therefore, we can implement the sampling process drawn from the intervened distribution as two steps.
First, we sample \(x\)  from \(P(X)\) . Second, we sample \(y\)  from the intervened conditional probability \(P(Y|do(X=x))\) . In short, we denote \(P(X\!=\!x)\)  as \(P(x)\)  and \(P(Y\!=\!y|do(X\!=\!x))\)  as \(P(y|do(x))\) .
