TECHNICAL REPORT
R-80
First version: Jun 2021
Last version: Feb 2022

The Causal-Neural Connection:
Expressiveness, Learnability, and Inference

Kevin Xia
CausalAI Lab
Columbia University

Kai-Zhan Lee
Bloomberg L.P.
Columbia University

kmx2000@columbia.edu

kl2792@columbia.edu

Yoshua Bengio
MILA
Université de Montréal
yoshua.bengio@mila.quebec

Elias Bareinboim
CausalAI Lab
Columbia University
eb@cs.columbia.edu

Abstract
One of the central elements of any causal inference is an object called structuralcausal model (SCM), which represents a collection of mechanisms and exogenous
sources of random variation of the system under investigation (Pearl, 2000). An
important property of many kinds of neural networks is universal approximability:
the ability to approximate any function to arbitrary precision. Given this property,
one may be tempted to surmise that a collection of neural nets is capable of learning
any SCM by training on data generated by that SCM. In this paper, we show
this is not the case by disentangling the notions of expressivity and learnability.
Specifically, we show that the causal hierarchy theorem (Thm. 1, Bareinboim et al.,2020), which describes the limits of what can be learned from data, still holds forneural models. For instance, an arbitrarily complex and expressive neural net isunable to predict the effects of interventions given observational data alone. Given
this result, we introduce a special type of SCM called a neural causal model (NCM),
and formalize a new type of inductive bias to encode structural constraints necessary
for performing causal inferences. Building on this new class of models, we focus
on solving two canonical tasks found in the literature known as causal identificationand estimation. Leveraging the neural toolbox, we develop an algorithm that is bothsufficient and necessary to determine whether a causal effect can be learned fromdata (i.e., causal identifiability); it then estimates the effect whenever identifiability
holds (causal estimation). Simulations corroborate the proposed approach.

1

Introduction

One of the most celebrated and relied upon results in the science of intelligence is the universality ofneural models. More formally, universality says that neural models can approximate any function(e.g., boolean, classification boundaries, continuous valued) with arbitrary precision given enoughcapacity in terms of the depth and breadth of the network [14, 26, 47, 53]. This result, combinedwith the observation that most tasks can be abstracted away and modeled as input/output – i.e., asfunctions – leads to the strongly held belief that under the right conditions, neural networks can solve
the most challenging and interesting tasks in AI. This belief is not without merits, and is corroborated
by ample evidence of practical successes, including in compelling tasks in computer vision [43],speech recognition [22], and game playing [54]. Given that the universality of neural nets is such acompelling proposition, we investigate this belief in the context of causal reasoning.
To start understanding the causal-neural connection – i.e., the non-trivial and somewhat intricate
relationship between these modes of reasoning – two standard objects in causal analysis will be
instrumental. First, we evoke a class of generative models known as the Structural Causal Model(SCM, for short) [58, Ch. 7]. In words, an SCM M∗ is a representation of a system that includes acollection of mechanisms and a probability distribution over the exogenous conditions (to be formallydefined later on). Second, any fully specified SCM M∗ induces a collection of distributions known as
the Pearl Causal Hierarchy (PCH) [5, Def. 9]. The importance of the PCH is that it formally delimits
35th Conference on Neural Information Processing Systems (NeurIPS 2021).

distinct cognitive capabilities (also known as layers; not to be confused with neural nets layers) thatcan be associated with the human activities of “seeing” (layer 1), “doing” (2), and “imagining” (3)[59, Ch. 1]. 1 Each of these layers can be expressed as a distinct formal language and represents
queries that can help to classify different types of inferences [5, Def. 8]. Together, these layers form astrict containment hierarchy [5, Thm. 1]. We illustrate these notions in Fig. 1(a) (left side), where
SCM M∗ induces layers L∗1 , L∗2 , L∗3 of the PCH.
Even though each possible statement withinthese capabilities has well-defined semantics
given the true SCM M∗ [58, Ch. 7], a challenging inferential task arises when one wishes
to recover part of the PCH when M∗ is only partially observed. This situation is typical in thereal world aside from some special settings inphysics and chemistry where the laws of nature
are understood with high precision.

PCH:

(a)
Unobserved
Nature/Truth(b)
Learned/Hypothesized

Structural Causal
Model M∗

NeuralModel N

L∗1

L∗2

L∗3

L1

L2

L3

Training (L∗1 = L1 )For concreteness, consider the setting where oneneeds to make a statement about the effect of a Figure 1:∗ The l.h.s. contains the unobserved true
new intervention (i.e., about layer 2), but only SCM M that induces the three layers of the PCH.
has observational data from layer 1, which is The r.h.s. contains an NCM that is trained to match
passively collected.2 Going back to the causal- in layer 1. The matching shading indicates that theneural connection, one could try to learn a neural two models agree w.r.t. L1 while not necessarily
model N using the observational dataset (layer agreeing w.r.t. layers 2 and 3.
1) generated by the true SCM M∗ , as illustrated in Fig. 1(b). Naturally, a basic consistency requirement is that N should be capable of generating the same distributions as M∗ ; in this case, their layer
1 predictions should match (i.e., L1 = L∗1 ). Given the universality of neural models, it is not hard tobelieve that these constraints can be satisfied in the large sample limit. The question arises of whether
the learned model N can act as a proxy, having the capability of predicting the effect of interventions
that matches the L2 distribution generated by the true (unobserved) SCM M∗ . 3 The answer to thisquestion cannot be ascertained in general, as will become evident later on (Corol. 1). The intuitive
reason behind this result is that there are multiple neural models that are equally consistent w.r.t. theL1 distribution of M∗ but generate different L2 -distributions. 4 Even though N may be expressive
enough to fully represent M∗ (as discussed later on), generating one particular parametrization of
N consistent with L1 is insufficient to provide any guarantee regarding higher-layer inferences, i.e.,
about predicting the effects of interventions (L2 ) or counterfactuals (L3 ).
The discussion above entails two tasks that have been acknowledged in the literature, namely, causal
effect identification and estimation. The first – causal identification – has been extensively studied,and general solutions have been developed, such as Pearl’s celebrated do-calculus [57]. Given theimpossibility described above, the ingredient shared across current non-neural solutions is to represent
assumptions about the unknown M∗ in the form of causal diagrams [58, 65, 7] or their equivalenceclasses [28, 60, 29, 71]. The task is then to decide whether there is a unique solution for the causal
query based on such assumptions. There are no neural methods today focused on solving this task.
The second task – causal estimation – is triggered when effects are determined to be identifiableby the first task. Whenever identifiability is obtained through the backdoor criterion/conditional
ignorability [58, Sec. 3.3.1], deep learning techniques can be leveraged to estimate such effects withimpressive practical performance [63, 52, 48, 31, 69, 70, 35, 64, 15, 25, 37, 30]. For effects that are
identifiable through causal functionals that are not necessarily of the backdoor-form (e.g., frontdoor,
1
This structure is named after Judea Pearl and is a central topic in his Book of Why (BoW), where it is also
called the “Ladder of Causation” [59]. For a more technical discussion on the PCH, we refer readers to [5].
2
The full inferential challenge is, in practice, more general since an agent may be able to perform interventions
and obtain samples from a subset of the PCH’s layers, while its goal is to make inferences about some otherparts of the layers [7, 46, 5]. This situation is not uncommon in RL settings [66, 17, 44, 45]. Still, for the sake ofspace and concreteness, we will focus on two canonical and more basic tasks found in the literature.
3
We defer a more formal discussion on how neural models could be used to assess the effect of interventions
to Sec. 2. Still, this is neither attainable in all universal neural architectures nor trivially implementable.
4
Pearl shared a similar observation in the BoW [59, p. 32]: “Without the causal model, we could not go fromrung (layer) one to rung (layer) two. This is why deep-learning systems (as long as they use only rung-one data
and do not have a causal model) will never be able to answer questions about interventions (...)”.

2

napkin), other optimization/statistical techniques can be employed that enjoy properties such as
double robustness and debiasedness [32, 33, 34]. Each of these approaches optimizes a particularestimand corresponding to one specific target interventional distribution.
Despite all the great progress achieved so far, it is still largely unknown how to perform the tasks
of causal identification and estimation in arbitrary settings using neural networks as a generativemodel, acting as a proxy for the true SCM M∗ . It is our goal here to develop a general causal-neuralframework that has the potential to scale to real-world, high-dimensional domains while preserving
the validity of its inferences, as in traditional symbolic approaches. In the same way that the causal
diagram encodes the assumptions necessary for the do-calculus to decide whether a certain query is
identifiable, our method encodes the same invariances as an inductive bias while being amenable togradient-based optimization, allowing us to perform both tasks in an integrated fashion (in a way,addressing Pearl’s concerns alluded to in Footnote 4). Specifically, our contributions are as follows:
1. [Sec. 2] We introduce a special yet simple type of SCM that is amenable to gradient descentcalled a neural causal model (NCM). We prove basic properties of this class of models, including
its universal expressiveness and ability to encode an inductive bias representing certain structuralinvariances (Thm. 1-3). Notably, we show that despite the NCM’s expressivity, it still abides by the
Causal Hierarchy Theorem (Corol. 1).
2. [Sec. 3] We formalize the problem of neural identification (Def. 8) and prove a duality between
identification in causal diagrams and in neural causal models (Thm. 4). We introduce an operational
way to perform inferences in NCMs (Corol. 2-3) and a sound and complete algorithm to jointly train
and decide effect identifiability for an NCM (Alg. 1, Corol. 4).
3. [Sec. 4] Building on these results, we develop a gradient descent algorithm to jointly identify andestimate causal effects (Alg. 2).
There are multiple ways of grounding these theoretical results. In Sec. 5, we perform experiments with
one possible implementation which support the feasibility of the proposed approach. All appendicesincluding proofs, experimental details, and examples can be found in the full technical report [68].
1.1 Preliminaries
In this section, we provide the necessary background to understand this work, following the presentation in [58]. An uppercase letter X indicates a random variable, and a lowercase letter x indicatesits corresponding value; bold uppercase X denotes a set of random variables, and lowercase letter x
its corresponding values. We use DX to denote the domain of X and DX = DX1 × · · · × DXk for
X = {X1 , . . . , Xk }. We denote P (X) as a probability distribution over a set of random variables X
and P (X = x) as the probability of X being equal to the value of x under the distribution P (X).
For simplicity, we will mostly abbreviate P (X = x) as simply P (x). The basic semantic frameworkof our analysis rests on structural causal models (SCMs) [58, Ch. 7], which are defined below.
Definition 1 (Structural Causal Model (SCM)). An SCM M is a 4-tuple ⟨U, V, F, P (U)⟩, where
U is a set of exogenous variables (or “latents”) that are determined by factors outside the model; V
is a set {V1 , V2 , . . . , Vn } of (endogenous) variables of interest that are determined by other variablesin the model – that is, in U ∪ V; F is a set of functions {fV1 , fV2 , . . . , fVn } such that each fi is amapping from (the respective domains of) UVi ∪ PaVi to Vi , where UVi ⊆ U, PaVi ⊆ V \ Vi , andthe entire set F forms a mapping from U to V. That is, for i = 1, . . . , n, each fi ∈ F is such thatvi ← fVi (paVi , uVi ); and P (u) is a probability function defined over the domain of U.
■
Each SCM M induces a causal diagram G where every Vi ∈ V is a vertex, there is a directed arrow(Vj → Vi ) for every Vi ∈ V and Vj ∈ P a(Vi ), and there is a dashed-bidirected arrow (Vj L9999K Vi )for every pair Vi , Vj ∈ V such that UVi and UVj are not independent. For further details on thisconstruction, see [5, Def. 13/16, Thm. 4]. The exogenous UVi ’s are not assumed independent (i.e.
Markovianity does not hold). We will consider here recursive SCMs, which implies acyclic diagrams,
and that the endogenous variables (V) are discrete and have finite domains.
We show next how an SCM M gives values to the PCH’s layers; for details on the semantics, see [5,Sec. 1.2]. Superscripts are omitted when unambiguous.
Definition 2 (Layers 1, 2 Valuations). An SCM M induces layer L2 (M), a set of distributions overV, one for each intervention x. For each Y ⊆ V,X
P M (yx ) =P (u),(1){u|Yx (u)=y}3

where Yx (u) is the solution for Y after evaluating Fx := {fVi : Vi ∈ V\X}∪{fX ← x : X ∈ X}.
The specific distribution P (V), where X is empty, is defined as layer L1 (M).
■In words, an external intervention forcing a set of variables X to take values x is modeled by replacing
the original mechanism fX for each X ∈ X with its corresponding value in x. This operation isrepresented formally by the do-operator, do(X = x), and graphically as the mutilation procedure.
For the definition of the third layer, L3 (M), see Def. 9 in Appendix A or [5, Def. 7].

2

Neural Causal Models and the Causal Hierarchy Theorem

In this section, we aim to resolve the tension between expressiveness and learnability (Fig. 1). To that
end, we define a special class of SCMs based on neural nets that is amenable to optimization and has
the potential to act as a proxy for the true, unobserved SCM M∗ .
c(θ) over variables V with
Definition 3 (NCM). A Neural Causal Model (for short, NCM) Mbbb P (U)⟩ such thatparameters θ = {θV : Vi ∈ V} is an SCM ⟨U, V, F,ib ⊆ {Ub is associated with some subset of variables C ⊆ V,
bC : C ⊆ V}, where each U• Ubb
and DUb = [0, 1] for all U ∈ U. (Unobserved confounding is present whenever |C| > 1.)• Fb = {fˆVi : Vi ∈ V}, where each fˆVi is a feedforward neural network parameterizedby θVi ∈ θ mapping values of UVi ∪ PaVi to values of Vi for some PaVi ⊆ V andb Vi ∈ C};
bC : UbC ∈ U,UVi = {U■bbbb ∈ U.
• P (U) is defined s.t. U ∼ Unif(0, 1) for each U
There is a number of remarks worth making at this point.
1. [Relationship NCM → SCM] By definition, all NCMs are SCMs, which means NCMs have thecapability of generating any distribution associated with the PCH’s layers.
2. [Relationship SCM ↛ NCM] On the other hand, not all SCMs are NCMs, since Def. 3 dictatesb follows uniform distributions in the unit interval and Fb are feedforward neural networks.
that U
3. [Non-Markovianity] For any two endogenous variables Vi and Vj , it is the case that UVi andb which will play a critical role in causality, not ruling out a priori
UVj might share an input from U,
the possibility of unobserved confounding and violations of Markovianity.
4. [Universality of Feedforward Nets] Feedforward networks are universal approximators [14, 26](see also [19]), and any probability distribution can be generated by the uniform one (e.g., seeb may be expressive enoughb P (U)⟩probability integral transform [1]). This suggests that the pair ⟨F,∗
for modeling M ’s mechanisms F and distribution P (U) without loss of generality.
5. [Generalizations / Other Model Classes] The particular modeling choices within the definition
above were made for the sake of explanation, and the results discussed here still hold for other,
arbitrary classes of functions and probability distributions, as shown in Appendix D.
To compare the expressiveness of NCMs and SCMs, we introduce the following definition.
Definition 4 (P(Li ) -Consistency). Consider two SCMs, M1 and M2 . M2 is said to be P(Li ) consistent (for short, Li -consistent) w.r.t. M1 if Li (M1 ) = Li (M2 ).
■This definition applies to NCMs since they are also SCMs. As shown below, NCMs can not only
approximate the collection of functions of the true SCM M∗ , but they can perfectly represent all theobservational, interventional, and counterfactual distributions. This property is, in fact, special andnot enjoyed by many neural models. (For examples and discussion, see Appendix C and D.1.)
Theorem 1 (NCM Expressiveness). For any SCM M∗ = ⟨U, V, F, P (U)⟩, there exists an NCM
b V, F,b s.t. Mc(θ) = ⟨U,b P (U)⟩c is L3 -consistent w.r.t. M∗ .
M■
Thm. 1 ascertains that there is no loss of expressive power using NCMs despite the constraints
imposed over its form, i.e., NCMs are as expressive as SCMs. One might be tempted to surmise,
therefore, that an NCM can be trained on the observed data and act as a proxy for the true SCM
cM∗ , and inferences about other quantities of M∗ can be done through computation directly in M.
Unfortunately, this is almost never the case: 5
5Multiple examples of this phenomenon are discussed in Appendix C.1 and [5, Sec. 1.2]

4

Corollary 1 (Neural Causal Hierarchy Theorem (N-CHT)). Let Ω∗ and Ω be the sets of all SCMs
and NCMs, respectively. We say that Layer j of the causal hierarchy for NCMs collapses to Layer ic) implies that Lj (M∗ ) = Lj (Mc) for all Mc ∈ Ω.
(i < j) relative to M∗ ∈ Ω∗ if Li (M∗ ) = Li (MThen, with respect to the Lebesgue measure over (a suitable encoding of L3 -equivalence classes of)
SCMs, the subset in which Layer j of NCMs collapses to Layer i has measure zero.
■This corollary highlights the fundamental challenge of performing inferences across the PCH layers
c is a suitable surrogate for the underlying SCM M∗ , in terms
even when the target object (NCM M)
of expressiveness and capability of generating the same observed distribution. That is, expressivenessdoes not mean that the learned object has the same empirical content as the generating model. For
concrete examples of the expressiveness of NCMs and why it is insufficient for causal inference, see
Examples 1 and 2 in Appendix C.1. Thus, structural assumptions are necessary to perform causal
inferences when using NCMs, despite their expressiveness. We discuss next how to incorporate thenecessary assumptions into an NCM to circumvent the limitation highlighted by Corol. 1.
2.1

A Family of Neural-Interventional Constraints (Inductive Bias)

In this section, we investigate constraints about M∗ that will narrow down the hypothesis
space and possibly allow for valid cross-layer inferences. One well-studied family of structural constraints comes in the form of a pair comprised of a collection of interventional distributions P and causal diagram G, known as a causal bayesian network (CBN) (Def. 15;
see also [5, Thm. 4])). The diagram G encodes constraints over the space of interventional
distributions P which are useful to perform cross-layer inferences (for details, see Appendix
C.2). For simplicity, we focus on interventional inferences from observational data. To compare the constraints entailed by distinct SCMs, we define the following notion of consistency:
Definition 5 (G-Consistency). Let G be the causal
diagram induced by SCM M∗ . For any SCM M, we
say that M is G-consistent (w.r.t. M∗ ) if G is a CBN
for L2 (M).
■(a)
Unobserved
Nature/Truth(b)
Learned/Hypothesized
CausalDiagram

SCM M∗= ⟨F ∗ , P (U∗ )⟩

G

c
NCM M
b
b P (U)⟩= ⟨F,

In the context of NCMs, this means that M would
G-Constraint
impose the same constraints over P as the true SCM
L∗2
L∗3
L1
L2
L3
∗
∗
PCH: L∗1
M (since G is also a CBN for L2 (M ) by [5,Thm. 4]). Whenever the corresponding diagram G
Training (L = L )is known, one should only consider NCMs that are
G-consistent. 6 We provide below a systematic way
Figure 2: The l.h.s. contains the true SCM
of constructing G-consistent NCMs.
M∗ that induces PCH’s three layers. The
2
Definition 6 (C -Component). For a causal diar.h.s. contains an NCM that is trained withgram G, a subset C ⊆ V is a complete confoundedlayer 1 data. The matching shading indicates2
component (for short, C -component) if any pairthat the two models agree with respect to L1
Vi , Vj ∈ C is connected with a bidirected arrow inwhile
not necessarily agreeing in layers 2 and
G and is maximal (i.e. there is no C 2 -component C′ 3. The causal diagram G entailed by M∗ is′for which C ⊂ C .)■c.
used as an inductive bias for M
Definition 7 (G-Constrained NCM (constructive)).
b s.t.
c as follows. (1) Choose U
Let G be the causal diagram induced by SCM M∗ . Construct NCM M
b if and only if C is a C 2 -component in G. (2) For each variable Vi ∈ V, choose PaV ⊆ V
bC ∈ UUis.t. for every Vj ∈ V, Vj ∈ PaVi if and only if there is a directed edge from Vj to Vi in G. Any
NCM in this family is said to be G-constrained. ■∗11Note that this represents a family of NCMs, not a unique one, since θ (the parameters of the neuralnetworks) are not yet specified by the construction, only the scope of the function and independenceb In contrast to SCMs where both ⟨F, P (u)⟩ canrelations among the sources of randomness (U).
freely vary, the degrees of freedom within NCMs come from θ. 7
6
Otherwise, the causal diagram can be learned through structural learning algorithms from observational
data [65, 61] or experimental data [41, 40, 27]. See the next footnote for a neural take on this task.
7
There is a growing literature that models SCMs using neural nets as functions, but which differ in natureand scope to our work. Broadly, these works assume Markovianity, which entails strong constraints over P (U)5We show next that an NCM constructed following the procedure dictated by Def. 7 encodes all theconstraints of the original causal diagram.
c(θ) is G-consistent.
Theorem 2 (NCM G-Consistency). Any G-constrained NCM M■

We show next the implications of imposing the structural constraints embedded in the causal diagram.
Theorem 3 (L2 -G Representation). For any SCM M∗ that induces causal diagram G, there exists ab V, F,b that is L2 -consistent w.r.t. M∗ .
c(θ) = ⟨U,b P (U)⟩
G-constrained NCM M■
The importance of this result stems from the fact that despite constraining the space of NCMs to
those compatible with G, the resultant family is still expressive enough to represent the entire Layer 2of the original, unobserved SCM M∗ .
Fig. 2 provides a mental picture useful to understand the results discussed so far. The true SCM M∗
generates the three layers of the causal hierarchy (left side), but in many settings only observationalc trained with this data is capable of perfectly representing L1
data (layer 1) is visible. An NCM M
c(right side). For almost any generating M∗ sampled from the space Ω∗ , there exists an NCM M
cthat exhibits the same behavior with respect to observational data (M is L1 -consistent) but exhibits
a different behavior with respect to interventional data. In other words, L1 underdetermines L2 .
(Similarly, L1 and L2 underdetermine L3 [5, Sec. 1.3].) Still, the true SCM M∗ also induces a causal
diagram G that encodes constraints over the interventional distributions. If we use this collection of
c may
constraints as an inductive bias, imposing G-consistency in the construction of the NCM, M
agree with those of the true M∗ under some conditions, which we will investigate in the next section.

3

The Neural Identification Problem

We now investigate the feasibility of causal inferences in the class of G-constrained NCMs. 8 The
first step is to refine the notion of identification [58, pp. 67] to inferences within this class of models.
Definition 8 (Neural Effect Identification). Consider any arbitrary SCM M∗ and the corresponding
causal diagram G and observational distribution P (V). The causal effect P (y | do(x)) is said to beneural-identifiable from the set of G-constrained NCMs Ω(G) and observational distribution P (V)ccc1 , Mc2 ∈ Ω(G) s.t.
if and only if P M1 (y | do(x)) = P M2 (y | do(x)) for every pair of models M
c1
c2
M∗
M
M
P
(V) = P (V) = P (V) > 0.
■Ω

In the context of graphical identifiability [58, Def. 3.2.4]
and do-calculus, an effect is identifiable if any SCM
in Ω∗ compatible with the observed causal diagramand capable of generating the observational distribution
matches the interventional query. If we constrain ourattention to NCMs, identification in the general classwould imply identification in NCMs, naturally, since itneeds to hold for all SCMs. On the other hand, it may beinsufficient to constrain identification within the NCM
class, like in Def. 8, since it is conceivable that the effect could match within the class (perhaps in a not very
expressive neural architecture) while there still exists an
SCM that generates the same observational distribution
and induces the same diagram, but does not agree in
the interventional query; see Example 7 in Appendix C.
The next result shows that this is never the case with
NCMs, and there is no loss of generality when deciding
identification through the NCM class.

Ω∗Structural Assumptions

c1
M

c2
M

G

M∗

Pb1(y|do(x)) =Pb2 (y|do(x))

P ∗(V)=Pb1 (V) = Pb2 (V)Observational(L1 ) Distributions
Data?

Interventional(L2 ) Distributions
Query

Figure 3: P (y | do(x)) is identifiablefrom P (V) and Ω(G) if for any SCM
c1 , Mc2 ∈ Ω (topM∗ ∈ Ω∗ and NCMs M
c1 , Mc2 , M∗ match in P (V) (botleft), M
tom left) and G (top right), then the NCMs
c1 , Mc2 also match in P (y | do(x)) (botM
tom right).

and, in the context of identification, implies that all effects are always identifiable; see Corol. 3. For instance,[21] attempts to learn the entire SCM from observational (L1 ) data, while [8, 10] also leverages experimental(L2 ) data. On the inference side, [42] focuses on estimating causal effects of labels on images.
8This is akin to what happens with the non-neural CHT [5, Thm. 1] and the subsequent use of causal diagrams
to encode the necessary inductive bias, and in which the do-calculus allows for cross-layer inferences directlyfrom the graphical representation [5, Sec. 1.4].

6

Theorem 4 (Graphical-Neural Equivalence (Dual ID)). Let Ω∗ be the set of all SCMs and Ω the set of
NCMs. Consider the true SCM M∗ and the corresponding causal diagram G. Let Q = P (y | do(x))
be the query of interest and P (V) the observational distribution. Then, Q is neural identifiable fromΩ(G) and P (V) if and only if it is identifiable from G and P (V).
■In words, Theorem 4 relates the solution space of these two classes of models, which means that theidentification status of a query is preserved across settings. For instance, if an effect is identifiablefrom the combination of a causal graph G and P (v), it will also be identifiable from G-constrained
NCMs (and the other way around). This is encouraging since our goal is to perform inferences
directly through neural causal models, within Ω(G), avoiding the symbolic nature of do-calculus
computation; the theorem guarantees that this is achievable in principle.
Corollary 2 (Neural Mutilation (Operational ID)). Consider the true SCM M∗ ∈ Ω∗ , causal∗
diagram G, the observational distribution P (V), and a target query Q equal to P M (y | do(x)).
c ∈ Ω(G) be a G-constrained NCM that is L1 -consistent with M∗ . If Q is identifiable from G
Let M
c, i.e., for eachand P (V), then Q is computable through a mutilation process on a proxy NCM Mc
X ∈ X, replacing the equation fx with a constant x (Q = PROC - MUTILATION(M ; X = x, Y)). ■Following the duality stated by Thm. 4, this result provides a practical, operational way of evaluating
queries in NCMs: inferences may be carried out through the process of mutilation, which gives
semantics to queries in the generating SCM M∗ (via Def. 2). What is interesting here is that the
proposition provides conditions under which this process leads to valid inferences, even when M∗ is
unknown, or when the mechanisms F and exogenous distribution P (U) of M∗ and the corresponding
c do not match. (For concreteness, refer to example 5functions and distribution of the proxy NCM M
c would work as if they were on M∗
in Appendix. C.) In words, inferences using mutilation on M
itself, and they would be correct so long as certain stringent properties were satisfied – L1 -consistency,
G-constraint, and identifiability. As shown earlier, if these properties are not satisfied, inferences
within a proxy model will almost never be valid, likely bearing no relationship with the ground truth.
(For fully worked out instances of this situation, refer to examples 2, 3, or 4 in Appendix C).
Still, one special class of SCMs in which any interventional distribution is identifiable is called
Markovian, where all Ui are assumed independent and affect only one endogenous variable Vi .
c is Markovian, P (y |Corollary 3 (Markovian Identification). Whenever the G-constrained NCM M
do(x)) is always identifiable through the process of mutilation in the proxy NCM (via Corol. 2). ■This is obviously not the case for general non- Algorithm 1: Identifying/estimating queries with NCMs.
Markovian models, which leads to the very
Input : causal query Q = P (y | do(x)), L1 data P (V), andproblem of identification. In these cases, we
causal diagram G∗
Output : P M (y | do(x)) if identifiable, FAIL otherwise.
need to decide whether the mutilation procedurec ← NCM(V, G)(Corol. 2) can, in principle, produce the correct 1 M// from Def. 7c∗canswer. We show in Alg. 1 a learning procedure 2 θmin← arg minθ P M(θ) (y | do(x)) s.t. L1 (M(θ))= P (V)c∗cthat decides whether a certain effect is identi- 3 θmax
← arg maxθ P M(θ) (y | do(x)) s.t. L1 (M(θ))= P (V)c ∗ )c ∗fiable from observational data. Intuitively, the 4 if P M(θmin (y | do(x)) ≠ P M(θmax ) (y | do(x)) thenreturn FAIL
procedure searches for two models that respec- 5
6 elsetively minimize and maximize the target query 7c ∗return P M(θmin ) (y | do(x))// choose min or max
while maintaining L1 -consistency with the data
arbitrarily
distribution. If the L2 query values induced by
the two models are equal, then the effect is identifiable, and the value is returned; otherwise, the effectis non-identifiable. Remarkably, the procedure is both necessary and sufficient, which means that all,and only, identifiable effects are classified as such by our procedure. This implies that, theoretically,
deep learning could be as powerful as the do-calculus in deciding identifiability. (For a more nuanced
discussion of symbolic versus optimization-based approaches for identification, see Appendix C.4.
For non-identifiability examples and further discussion, see C.3.)
Corollary 4 (Soundness and Completeness). Let Ω∗ be the set of all SCMs, M∗ ∈ Ω∗ be the true
b be the result from
SCM inducing causal diagram G, Q = P (y | do(x)) be a query of interest, and Q
running Alg. 1 with inputs P ∗ (V) = L1 (M∗ ) > 0, G, and Q. Then Q is identifiable from G andb is not FAIL. Moreover, if Q
b is not FAIL, then Q
b = P M∗ (y | do(x)).
P ∗ (V) if and only if Q■
7

4

The Neural Estimation Problem

While identifiability is fully solved by the asymptotic theory discussed so far (i.e., it is both necessary
and sufficient), we now consider the problem of estimating causal effects in practice under imperfectoptimization and finite samples and computation. For concreteness, we discuss next the discrete
case with binary variables, but our construction extends naturally to categorical and continuousc(G; θ) =variables (see Appendix B). We propose next a construction of a G-constrained NCM Mbbb⟨U, V, F, P (U)⟩, which is a possible instantiation of Def. 7:
b := {UC : C ∈ C 2 (G)} ∪ {GV : Vi ∈ V},:= V, U
V

 i




log σ(ϕVi (paVi , ucVi ; θVi ))j=1
Fb:= fVi := arg maxj∈{0,1} gj,Vi +,(2)
log(1 − σ(ϕVi (paVi , ucVi ; θVi ))) j = 0P (U)b
:= {UC ∼ Unif(0, 1) : UC ∈ U} ∪
{Gj,Vi ∼ Gumbel(0, 1) : Vi ∈ V, j ∈ {0, 1}},
where V are the nodes of G; σ : R → (0, 1) is the sigmoid activation function; C 2 (G) is the set of
C 2 -components of G; each Gj,Vi is a standard Gumbel random variable [24]; each ϕVi (·; θVi ) is aneural net parameterized by θVi ∈ θ; paVi are the values of the parents of Vi ; and ucVi are the valuesof UcVi := {UC : UC ∈ U s.t. Vi ∈ C}. The parameters θ are not yet specified and must be learned
through training to enforce L1 -consistency (Def. 4).
Let Uc and G denote the latent C 2 -component variables and Gumbel random variables, respectively.
cc
To estimate P M (v) and P M (y | do(x)) given Eq. 2, we may compute the probability mass of adatapoint v with intervention do(X = x) (X is empty when observational) as:


m
Y
1 X Y
c
P M (G;θ) (v | do(x)) = E σ̃vi  ≈σ̃vi ,(3)
m j=1
P (uc )Vi ∈V\XVi ∈V\Xσ(ϕi (paVi , ucVi ; θVi ))vi = 1cand {ucj }m
j=1 are samples from P (U ). Here,
1 − σ(ϕi (paVi , ucVi ; θVi )) vi = 0
we assume v is consistent with x (the values of X ∈ X in v match the corresponding ones of x).
cOtherwise, P M (G;θ) (v | do(x)) = 0. For numerical stability of each ϕi (·), we work in log-space anduse the log-sum-exp trick.


where σ̃vi :=Alg. 1 (lines 2-3) requires non-trivial evaluations ofcexpressions like arg maxθ P M (y | do(x)) while enforcing L1 -consistency. Whenever only finite samples are available {vk }nk=1 ∼ P ∗ (V), the parametersof an L1 -consistent NCM may be estimated by minimizing data negative log-likelihood:hicθ ∈ arg min EP ∗ (v) − log P M (G;θ) (v)θn≈ arg minθ1X
c(G;θ)
M− log Pbm(vk ).
n(4)

k=1

To simultaneously maximize P M (y | do(x)), wecM
subtract a weighted second term log Pbm(y | do(x)),
nresulting in the objective L({vk }k=1 ) equal to
c

n

1X
c
c
M
M
− log Pbm(vk ) − λ log Pbm(y | do(x)), (5)nAlgorithm 2: Training Model
Input : Data {vk }nk=1 , variables V, X ⊆ V, x ∈ DX ,Y ⊆ V, y ∈ DY , causal diagram G, number ofMonte Carlo samples m, regularization constant λ,learning rate ηc ← NCM(V, G)
M// from Def. 7
Initialize parameters θmin and θmax
for k ← 1 to n do// Estimate from Eq. 3c(θ min ), V, vk , ∅, ∅, m)4p̂min ← Estimate(Mc(θ max ), V, vk , ∅, ∅, m)5p̂max ← Estimate(M6q̂ min ← 0
7q̂ max ← 0
8for v ∈ DV do
9
if Consistent(v, y) then10q̂min ← q̂min +c min ), V, v, X, x, m)
Estimate(M(θ11q̂max ← q̂max +c max ), V, v, X, x, m)
Estimate(M(θ
1
2
3

12
13
14
15

// L from Eq. 5
Lmin ← − log p̂min − λ log(1 − q̂ min )Lmax ← − log p̂max − λ log q̂ max
θ min ← θ min + η∇Lminθ max ← θ max + η∇Lmax

k=1

where λ is initially set to a high value and decreasescMduring training. To minimize, we instead subtract λ log(1 − Pbm(y | do(x))) from the log-likelihood.
8Figure 4: Experimental results on deciding identifiability with NCMs. Top: Graphs from left toright: (ID cases) back-door, front-door, M, napkin; (not ID cases) bow, extended bow, IV, bad M.
Middle: Classification accuracy over 3,000 training epochs from running hypothesis test on Eq. 6
with τ = 0.01 (blue), 0.03 (green), 0.05 (red). Bottom: (1, 5, 10, 25, 50, 75, 90, 95, 99)-percentiles
for max-min gaps over 3000 training epochs.

Alg. 2 is one possible way of optimizing the parameters θ required in lines 2,3 of Alg. 1. Eq. 5 isamenable to optimization through standard gradient descent tools, e.g., [38, 51, 50]. 9 10
One way of understanding Alg. 1 is as a search within the Ω(G) space for two NCM parameterizations,∗∗θminand θmax, that minimizes/maximizes the interventional distribution, respectively. Whenever the
optimization ends, we can compare the corresponding P (y | do(x)) and determine whether an effectis identifiable. With perfect optimization and unbounded resources, identifiability entails the equality
between these two quantities. In practice, we rely on a hypothesis testing step such asc(θmax )) − f (Mc(θmin ))| < τ
|f (M

(6)

for quantity of interest f and a certain threshold τ . This threshold is somewhat similar to a significancelevel in statistics and can be used to control certain types of errors. In our case, the threshold τ can be
determined empirically. For further discussion, see Appendix B.

5

Experiments

We start by evaluating NCMs (following Eq. 2) in their ability to decide whether an effect is
identifiable through Alg. 2. Observational data is generated from 8 different SCMs, and theircorresponding causal diagrams are shown in Fig. 4 (top part), and Appendix B provides further detailsof the parametrizations. Since the NCM does not have access to the true SCM, the causal diagram andgenerated datasets are passed to the algorithm to decide whether an effect is identifiable. The target
effect is P (Y | do(X)), and the quantity we optimize is the average treatment effect (ATE) of X on
Y , AT E M (X, Y ) = EM [Y | do(X = 1)] − EM [Y | do(X = 0)]. Note that if the outcome Y isbinary, as in our examples, E[Y | do(X = x)] = P (Y = 1|do(X = x)). The effect is identifiablethrough do-calculus in the settings represented by Fig. 4 in the left part, and not identifiable in right.
The bottom row of Fig. 4 shows the max-min gaps, the l.h.s of Eq. 6 with f (M) = ATEM (X, Y ),over 3000 training epochs. The parameter λ is set to 1 at the beginning, and decreases logarithmicallyover each epoch until it reaches 0.001 at the end of training. The max-min gaps can be used to classify
the quantity as “ID” or “non-ID” using the hypothesis testing procedure described in Appendix B. The
classification accuracies per training epoch are shown in Fig. 4 (middle row). Note that in identifiablesettings, the gaps slowly reduce to 0, while the gaps rapidly grow and stay high throughout training in
the unidentifiable ones. The classification accuracy for ID cases then gradually increases as training
9

Our approach is flexible and may take advantage of these different methods depending on the context. Therec
are a number of alternatives for minimizing the discrepancy between P ∗ and P M , including minimizing divergences, such as maximum mean discrepancy [23] or kernelized Stein discrepancy [49], performing variational
inference [9], or generative adversarial optimization [20].
10The NCM can be extended to the continuous case by replacing the Gumbel-max trick on σ(ϕi (·)) with amodel that directly computes a probability density given a data point, e.g., normalizing flow [62] or VAE [39].

9progresses, while accuracy for non-ID cases remain high the entire time (perfect in the bow and IV
cases).
In the identifiable settings, we also evaluate theperformance of the NCM at estimating the correctcausal effect, as shown in Fig. 5. As a generativemodel, the NCM is capable of generating samples
from both P (V) and identifiable L2 distributions
like P (Y | do(X)). We compare the NCM to a naïve
generative model trained via likelihood maximization
fitted on P (V) without using the inductive bias of theNCM. Since the naïve model is not defined to sample
from P (y | do(x)), this shows the implications ofarbitrarily choosing P (y | do(x)) = P (y | x). Bothmodels improve at fitting P (V) with more samples,but the naïve model fails to learn the correct ATE
except in case (c), where P (y | do(x)) = P (y | x).
Further, the NCM is competitive with WERM [33],a state-of-the-art estimation method that directly targets estimating the causal effect without generating
samples.

6

Figure 5: NCM estimation results for ID
cases. Columns a, b, c, d correspond to thesame graphs as a, b, c, d in Fig. 4. Top:KL divergence of P (V) induced by naïve
model (blue) and NCM (orange) compared to∗P M (V). Bottom: MAE of ATE of naïve
model (blue), NCM (orange), and WERM
(green). Plots in log-log scale.

Conclusions

In this paper, we introduced neural causal models (NCMs) (Def. 3, 18), a special class of SCMs
trainable through gradient-based optimization techniques. We showed that despite being as expressive as SCMs (Thm. 1), NCMs are unable to perform cross-layer inferences in general (Corol. 1).
Disentangling expressivity and learnability, we formalized a new type of inductive bias based on nonparametric, structural properties of the generating SCM, accompanied with a constructive procedurethat allows NCMs to represent constraints over the space of interventional distributions akin to causal
diagrams (Thm. 2). We showed that NCMs with this bias retain their full expressivity (Thm. 3) but are
now empowered to solve canonical tasks in causal inference, including the problems of identificationand estimation (Thm. 4). We grounded these results by providing a training procedure that is bothsound and complete (Alg. 1, 2, Cor. 4). Practically speaking, different neural implementations –combination of architectures, training algorithms, loss functions – can leverage the framework results
introduced in this work (Appendix D.1). We implemented one of such alternatives as a proof ofconcept, and experimental results support the feasibility of the proposed approach. After all, we hope
the causal-neural framework established in this paper can help develop more principled and robust
architectures to empower the next generation of AI systems. We expect these systems to combine
the best of both worlds by (1) leveraging causal inference capabilities of processing the structuralinvariances found in nature to construct more explainable and generalizable decision-making procedures, and (2) leveraging deep learning capabilities to scale inferences to handle challenging, highdimensional settings found in practice.

Acknowledgements
We thank Judea Pearl, Richard Zemel, Yotam Alexander, Juan Correa, Sanghack Lee, and Junzhe
Zhang for their valuable feedback. Kevin Xia and Elias Bareinboim were supported in part byfunding from the NSF, Amazon, JP Morgan, and The Alfred P. Sloan Foundation. Yoshua Bengio
was supported in part by funding from CIFAR, NSERC, Samsung, and Microsoft.

References[1] Angus, J. E. (1994). The probability integral transform and related results. SIAM Review,
36(4):652–654.
[2] Appel, L. J., Moore, T. J., Obarzanek, E., Vollmer, W. M., Svetkey, L. P., Sacks, F. M., Bray,
G. A., Vogt, T. M., Cutler, J. A., Windhauser, M. M., and et al. (1997). A clinical trial of the effects
of dietary patterns on blood pressure. New England Journal of Medicine, 336(16):1117–1124.
10

[3] Balke, A. and Pearl, J. (1994). Counterfactual Probabilities: Computational Methods, Bounds,
and Applications. In de Mantaras, R. L. and D.˜Poole, editors, Uncertainty in Artificial Intelligence
10, pages 46–54. Morgan Kaufmann, San Mateo, CA.
[4] Bareinboim, E., Brito, C., and Pearl, J. (2012). Local Characterizations of Causal Bayesian
Networks. In Croitoru, M., Rudolph, S., Wilson, N., Howse, J., and Corby, O., editors, Graph
Structures for Knowledge Representation and Reasoning, pages 1–17, Berlin, Heidelberg. Springer
Berlin Heidelberg.
[5] Bareinboim, E., Correa, J. D., Ibeling, D., and Icard, T. (2020). On Pearl’s Hierarchy and theFoundations of Causal Inference. Technical Report R-60, Causal AI Lab, Columbia University,
Also, In “Probabilistic and Causal Inference: The Works of Judea Pearl” (ACM Turing Series), inpress.
[6] Bareinboim, E., Forney, A., and Pearl, J. (2015). Bandits with unobserved confounders: A causal
approach. In Advances in Neural Information Processing Systems, pages 1342–1350.
[7] Bareinboim, E. and Pearl, J. (2016). Causal inference and the data-fusion problem. In Shiffrin,
R. M., editor, Proceedings of the National Academy of Sciences, volume 113, pages 7345–7352.
National Academy of Sciences.
[8] Bengio, Y., Deleu, T., Rahaman, N., Ke, R., Lachapelle, S., Bilaniuk, O., Goyal, A., and Pal, C.
(2020). A meta-transfer objective for learning to disentangle causal mechanisms. In Proceedingsof the International Conference on Learning Representations (ICLR).
[9] Blei, D. M., Kucukelbir, A., and McAuliffe, J. D. (2017). Variational inference: A review forstatisticians. Journal of the American Statistical Association, 112(518):859–877.
[10] Brouillard, P., Lachapelle, S., Lacoste, A., Lacoste-Julien, S., and Drouin, A. (2020). Differentiable causal discovery from interventional data. In Larochelle, H., Ranzato, M., Hadsell,R., Balcan, M. F., and Lin, H., editors, Advances in Neural Information Processing Systems,
volume 33, pages 21865–21877. Curran Associates, Inc.
[11] Casella, G. and Berger, R. (2001). Statistical Inference, pages 54–55. Duxbury Resource Center.
[12] Chen, T. and Guestrin, C. (2016). XGBoost: A scalable tree boosting system. In Proceedings ofthe 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining,
KDD ’16, pages 785–794, New York, NY, USA. ACM.
[13] Correa, J. and Bareinboim, E. (2020). General transportability of soft interventions: Completeness results. In Larochelle, H., Ranzato, M., Hadsell, R., Balcan, M. F., and Lin, H., editors,
Advances in Neural Information Processing Systems, volume 33, pages 10902–10912, Vancouver,
Canada. Curran Associates, Inc.
[14] Cybenko, G. (1989). Approximation by superpositions of a sigmoidal function. Mathematics ofControl, Signals, and Systems (MCSS), 2(4):303–314.
[15] Du, X., Sun, L., Duivesteijn, W., Nikolaev, A., and Pechenizkiy, M. (2021). Adversarialbalancing-based representation learning for causal effect inference with observational data. Data
Mining and Knowledge Discovery.
[16] Falcon, W. and Cho, K. (2020). A framework for contrastive self-supervised learning anddesigning a new approach. arXiv preprint arXiv:2009.00104.
[17] Forney, A., Pearl, J., and Bareinboim, E. (2017). Counterfactual Data-Fusion for Online
Reinforcement Learners. In Proceedings of the 34th International Conference on Machine
Learning.
[18] Germain, M., Gregor, K., Murray, I., and Larochelle, H. (2015). Made: Masked autoencoder
for distribution estimation. In Bach, F. and Blei, D., editors, Proceedings of the 32nd International
Conference on Machine Learning, volume 37 of Proceedings of Machine Learning Research,
pages 881–889, Lille, France. PMLR.
[19] Goodfellow, I., Bengio, Y., and Courville, A. (2016). Deep Learning. MIT Press.
[20] Goodfellow, I., Pouget-Abadie, J., Mirza, M., Xu, B., Warde-Farley, D., Ozair, S., Courville,A., and Bengio, Y. (2014). Generative adversarial nets. In Ghahramani, Z., Welling, M., Cortes,
C., Lawrence, N., and Weinberger, K. Q., editors, Advances in Neural Information Processing
Systems, volume 27, pages 2672–2680. Curran Associates, Inc.
11

[21] Goudet, O., Kalainathan, D., Caillou, P., Lopez-Paz, D., Guyon, I., and Sebag, M. (2018).
Learning Functional Causal Models with Generative Neural Networks. In Explainable andInterpretable Models in Computer Vision and Machine Learning, Springer Series on Challenges
in Machine Learning. Springer International Publishing.
[22] Graves, A. and Jaitly, N. (2014). Towards end-to-end speech recognition with recurrent neuralnetworks. In Xing, E. P. and Jebara, T., editors, Proceedings of the 31st International Conference
on Machine Learning, volume 32 of Proceedings of Machine Learning Research, pages 1764–1772,
Bejing, China. PMLR.
[23] Gretton, A., Borgwardt, K., Rasch, M., Schölkopf, B., and Smola, A. (2007). A kernel method
for the two-sample-problem. In Schölkopf, B., Platt, J., and Hoffman, T., editors, Advances in
Neural Information Processing Systems, volume 19, pages 513–520. MIT Press.
[24] Gumbel, E. (1954). Statistical Theory of Extreme Values and Some Practical Applications: A
Series of Lectures. Applied mathematics series. U.S. Government Printing Office.
[25] Guo, R., Cheng, L., Li, J., Hahn, P. R., and Liu, H. (2020). A survey of learning causality withdata. ACM Computing Surveys, 53(4):1–37.
[26] Hornik, K. (1991). Approximation capabilities of multilayer feedforward networks. Neural
Networks, 4(2):251 – 257.
[27] Jaber, A., Kocaoglu, M., Shanmugam, K., and Bareinboim, E. (2020). Causal discovery fromsoft interventions with unknown targets: Characterization and learning. In Larochelle, H., Ranzato,
M., Hadsell, R., Balcan, M. F., and Lin, H., editors, Advances in Neural Information Processing
Systems, volume 33, pages 9551–9561, Vancouver, Canada. Curran Associates, Inc.
[28] Jaber, A., Zhang, J., and Bareinboim, E. (2018). Causal identification under Markov equivalence.
In Proceedings of the 34th Conference on Uncertainty in Artificial Intelligence, pages 978–987.
AUAI Press.
[29] Jaber, A., Zhang, J., and Bareinboim, E. (2019). Causal identification under Markov equivalence:
Completeness results. In Chaudhuri, K. and Salakhutdinov, R., editors, Proceedings of the 36th
International Conference on Machine Learning, volume 97, pages 2981–2989. PMLR.
[30] Johansson, F. D., Shalit, U., Kallus, N., and Sontag, D. (2021). Generalization bounds andrepresentation learning for estimation of potential outcomes and causal effects.
[31] Johansson, F. D., Shalit, U., and Sontag, D. (2016). Learning representations for counterfactual
inference. In Proceedings of the 33rd International Conference on International Conference on
Machine Learning - Volume 48, ICML’16, page 3020–3029. JMLR.org.
[32] Jung, Y., Tian, J., and Bareinboim, E. (2020a). Estimating causal effects using weighting-based
estimators. In Proceedings of the 34th AAAI Conference on Artificial Intelligence, New York, NY.
AAAI Press.
[33] Jung, Y., Tian, J., and Bareinboim, E. (2020b). Learning causal effects via weighted empiricalrisk minimization. In Larochelle, H., Ranzato, M., Hadsell, R., Balcan, M. F., and Lin, H., editors,
Advances in Neural Information Processing Systems, volume 33, pages 12697–12709, Vancouver,
Canada. Curran Associates, Inc.
[34] Jung, Y., Tian, J., and Bareinboim, E. (2021). Estimating identifiable causal effects throughdouble machine learning. In Proceedings of the 35th AAAI Conference on Artificial Intelligence,
number R-69, Vancouver, Canada. AAAI Press.
[35] Kallus, N. (2020). DeepMatch: Balancing deep covariate representations for causal inference
using adversarial training. In III, H. D. and Singh, A., editors, Proceedings of the 37th International
Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research,
pages 5067–5077. PMLR.
[36] Karpathy, A. (2018). pytorch-made. https://github.com/karpathy/pytorch-made[Source Code].
[37] Kennedy, E. H., Balakrishnan, S., and Wasserman, L. (2021). Semiparametric counterfactual
density estimation.
[38] Kingma, D. P. and Ba, J. (2015). Adam: A method for stochastic optimization. In Bengio, Y.
and LeCun, Y., editors, 3rd International Conference on Learning Representations, ICLR 2015,
San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
12

[39] Kingma, D. P. and Welling, M. (2014). Auto-encoding variational bayes. In Bengio, Y. and
LeCun, Y., editors, 2nd International Conference on Learning Representations, ICLR 2014, Banff,
AB, Canada, April 14-16, 2014, Conference Track Proceedings.
[40] Kocaoglu, M., Jaber, A., Shanmugam, K., and Bareinboim, E. (2019). Characterization andlearning of causal graphs with latent variables from soft interventions. In Wallach, H., Larochelle,
H., Beygelzimer, A., d’Alché Buc, F., Fox, E., and Garnett, R., editors, Advances in Neural
Information Processing Systems 32, pages 14346–14356, Vancouver, Canada. Curran Associates,Inc.
[41] Kocaoglu, M., Shanmugam, K., and Bareinboim, E. (2017a). Experimental design for learningcausal graphs with latent variables. In Guyon, I., Luxburg, U. V., Bengio, S., Wallach, H., Fergus,
R., Vishwanathan, S., and Garnett, R., editors, Advances in Neural Information Processing Systems
30, pages 7018–7028. Curran Associates, Inc.
[42] Kocaoglu, M., Snyder, C., Dimakis, A. G., and Vishwanath, S. (2017b). Causalgan: Learningcausal implicit generative models with adversarial training.
[43] Krizhevsky, A., Sutskever, I., and Hinton, G. E. (2012). Imagenet classification with deep
convolutional neural networks. In Pereira, F., Burges, C. J. C., Bottou, L., and Weinberger, K. Q.,
editors, Advances in Neural Information Processing Systems, volume 25, pages 1097–1105. Curran
Associates, Inc.
[44] Lee, S. and Bareinboim, E. (2018). Structural causal bandits: Where to intervene? In Bengio,S., Wallach, H., Larochelle, H., Grauman, K., Cesa-Bianchi, N., and Garnett, R., editors, Advancesin Neural Information Processing Systems 31, pages 2568–2578, Montreal, Canada. Curran
Associates, Inc.
[45] Lee, S. and Bareinboim, E. (2020). Characterizing optimal mixed policies: Where to intervene
and what to observe. In Larochelle, H., Ranzato, M., Hadsell, R., Balcan, M. F., and Lin, H.,
editors, Advances in Neural Information Processing Systems, volume 33, pages 8565–8576,
Vancouver, Canada. Curran Associates, Inc.
[46] Lee, S., Correa, J. D., and Bareinboim, E. (2019). General Identifiability with Arbitrary
Surrogate Experiments. In Proceedings of the Thirty-Fifth Conference Annual Conference on
Uncertainty in Artificial Intelligence, Corvallis, OR. AUAI Press, in press.
[47] Leshno, M., Lin, V. Y., Pinkus, A., and Schocken, S. (1993). Multilayer feedforward networks
with a nonpolynomial activation function can approximate any function. Neural Networks, 6(6):861– 867.
[48] Li, S. and Fu, Y. (2017). Matching on balanced nonlinear representations for treatment effects
estimation. In Guyon, I., Luxburg, U. V., Bengio, S., Wallach, H., Fergus, R., Vishwanathan, S.,
and Garnett, R., editors, Advances in Neural Information Processing Systems, volume 30, pages
929–939. Curran Associates, Inc.
[49] Liu, Q., Lee, J., and Jordan, M. (2016). A kernelized stein discrepancy for goodness-of-fit tests.
In Balcan, M. F. and Weinberger, K. Q., editors, Proceedings of The 33rd International Conference
on Machine Learning, volume 48 of Proceedings of Machine Learning Research, pages 276–284,
New York, New York, USA. PMLR.
[50] Loshchilov, I. and Hutter, F. (2017). SGDR: stochastic gradient descent with warm restarts.
In 5th International Conference on Learning Representations, ICLR 2017, Toulon, France, April
24-26, 2017, Conference Track Proceedings. OpenReview.net.
[51] Loshchilov, I. and Hutter, F. (2019). Decoupled weight decay regularization. In 7th International
Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019.
OpenReview.net.
[52] Louizos, C., Shalit, U., Mooij, J., Sontag, D., Zemel, R., and Welling, M. (2017). Causal effectinference with deep latent-variable models. In Proceedings of the 31st International Conference
on Neural Information Processing Systems, NIPS’17, page 6449–6459, Red Hook, NY, USA.
Curran Associates Inc.
[53] Lu, Z., Pu, H., Wang, F., Hu, Z., and Wang, L. (2017). The expressive power of neural networks:
A view from the width. In Guyon, I., Luxburg, U. V., Bengio, S., Wallach, H., Fergus, R.,
Vishwanathan, S., and Garnett, R., editors, Advances in Neural Information Processing Systems,
volume 30, pages 6231–6239. Curran Associates, Inc.
13

[54] Mnih, V., Kavukcuoglu, K., Silver, D., Graves, A., Antonoglou, I., Wierstra, D., and Riedmiller,
M. (2013). Playing atari with deep reinforcement learning. In NIPS Deep Learning Workshop.
[55] Paszke, A., Gross, S., Chintala, S., Chanan, G., Yang, E., DeVito, Z., Lin, Z., Desmaison, A.,
Antiga, L., and Lerer, A. (2017). Automatic differentiation in pytorch.
[56] Pearl, J. (1988). Probabilistic Reasoning in Intelligent Systems. Morgan Kaufmann, USA.
[57] Pearl, J. (1995). Causal diagrams for empirical research. Biometrika, 82(4):669–688.
[58] Pearl, J. (2000). Causality: Models, Reasoning, and Inference. Cambridge University Press,
New York, NY, USA, 2nd edition.
[59] Pearl, J. and Mackenzie, D. (2018). The Book of Why. Basic Books, New York.
[60] Perković, E., Textor, J., Kalisch, M., and H. Maathuis, M. (2018). Complete GraphicalCharacterization and Construction of Adjustment Sets in Markov Equivalence Classes of Ancestral
Graphs. Journal of Machine Learning Research, 18.
[61] Peters, J., Janzing, D., and Schlkopf, B. (2017). Elements of Causal Inference: Foundationsand Learning Algorithms. The MIT Press.
[62] Rezende, D. and Mohamed, S. (2015). Variational inference with normalizing flows. In Bach, F.
and Blei, D., editors, Proceedings of the 32nd International Conference on Machine Learning,volume 37 of Proceedings of Machine Learning Research, pages 1530–1538, Lille, France. PMLR.
[63] Shalit, U., Johansson, F. D., and Sontag, D. (2017). Estimating individual treatment effect:
generalization bounds and algorithms. In Precup, D. and Teh, Y. W., editors, Proceedings ofthe 34th International Conference on Machine Learning, volume 70 of Proceedings of Machine
Learning Research, pages 3076–3085, International Convention Centre, Sydney, Australia. PMLR.
[64] Shi, C., Blei, D. M., and Veitch, V. (2019). Adapting neural networks for the estimation oftreatment effects. In Wallach, H. M., Larochelle, H., Beygelzimer, A., d’Alché-Buc, F., Fox,
E. B., and Garnett, R., editors, Advances in Neural Information Processing Systems 32: Annual
Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019,
Vancouver, BC, Canada, pages 2503–2513.
[65] Spirtes, P., Glymour, C. N., and Scheines, R. (2000). Causation, Prediction, and Search. MIT
Press, Cambridge, MA, 2nd edition.
[66] Sutton, R. S. and Barto, A. G. (2018). Reinforcement Learning: An Introduction. The MIT
Press, second edition.
[67] Tian, J. and Pearl, J. (2002). A General Identification Condition for Causal Effects. In
Proceedings of the Eighteenth National Conference on Artificial Intelligence (AAAI 2002), pages
567–573, Menlo Park, CA. AAAI Press/The MIT Press.
[68] Xia, K., Lee, K.-Z., Bengio, Y., and Bareinboim, E. (2021). The Causal-Neural Connection:
Expressiveness, Learnability, Inference. Technical Report Technical Report R-80, Causal AI Lab,
Columbia University, USA.
[69] Yao, L., Li, S., Li, Y., Huai, M., Gao, J., and Zhang, A. (2018). Representation learning
for treatment effect estimation from observational data. In Bengio, S., Wallach, H., Larochelle,
H., Grauman, K., Cesa-Bianchi, N., and Garnett, R., editors, Advances in Neural Information
Processing Systems, volume 31, pages 2633–2643. Curran Associates, Inc.
[70] Yoon, J., Jordon, J., and van der Schaar, M. (2018). GANITE: Estimation of individualized
treatment effects using generative adversarial nets. In International Conference on Learning
Representations.
[71] Zhang, J. (2008). On the completeness of orientation rules for causal discovery in the presenceof latent confounders and selection bias. Artificial Intelligence, 172(16-17):1873–1896.
[72] Zhang, J. and Bareinboim, E. (2021). Non-Parametric Methods for Partial Identification of
Causal Effects. Technical Report Technical Report R-72, Columbia University, Department ofComputer Science, New York.
[73] Zhang, J., Tian, J., and Bareinboim, E. (2021). Partial Identification of Counterfactual Distributions. Technical Report Technical Report R-78, Columbia University, Department of Computer
Science, New York.

14

A

ProofsIn this section, we provide proofs of the statements in the main body of the paper.
A.1

Proofs of Theorem 1 and Corollary 1

In addition to Def. 2, defining layers 1 and 2 of the PCH, we also require a definition for layer
3. While Def. 2 shows how the SCM valuates observational and interventional distributions, thefollowing definition of layer 3 ([5, Def. 7]) shows how the SCM valuates counterfactual distributions,a family of distributions even more expressive than those from lower layers.
Definition 9 (Layer 3 Valuation). An SCM M = ⟨U, V, F, P (U)⟩ induces a family of joint
distributions over counterfactual events Yx , . . . , Zw , for any Y, Z, . . . , X, W ⊆ V:X
P M (yx , . . . , zw ) =P (u).
(7){u | Yx (u)=y,..., Zw (u)=z}■
For the expressiveness proofs of this paper, we leverage some of the notation and results from [72].
These results focus on the idea of a canonical form of SCMs, first explored in a special case by [3].
Let M = ⟨U, V, F, P (U)⟩ be any SCM. For each V ∈ V, we denote HV = {hV : DpaV → DV }as the set of all possible functions mapping from the domain of the parents paV to the domain of V .
(1)(m )We will order the elements of HV as hV , . . . , hV V , where mV = |HV |. Since HV fully exhausts
(1)
(m )
(r )
all possible functions, we can partition DUV into sets DUV , . . . , DUVV such that uV ∈ DUVV if and(r )only if fV (·, uV ) = hV V .
Lemma 1 ([72, Lem. 1]). For an SCM M = ⟨U, V, F, P (U)⟩, for each V ∈ V, function fV ∈ F
can be expressed asfV (paV , uV ) =

mV
X

n
o
(r )
(r )
hV V (paV )1 uV ∈ DUVV

rV =1

■
Definition 10 (Canonical SCM). A canonical SCM is an SCM M = ⟨U, V, F, P (U)⟩ such that
1. U = {RV : V ∈ V}, where DRV = {1, . . . , mV } (where mV = |{hV : DpaV → DV }|)for each V ∈ V.
2. For each V ∈ V, fV ∈ F is defined as(r )fV (paV , rV ) = hV V (paV ).
■Lemma 2. For any SCM M = ⟨U, V, F, P (U)⟩, there exists a canonical SCM MCM =⟨UCM , V, FCM , P (UCM )⟩ such that MCM is L3 -consistent with M.
■
Proof. Since UCM and FCM are already fixed, we choose P (UCM ) to fix our choice of MCM . Forr ∈ DUCM , we choose
P MCM (UCM = r)
=P

(8)

MCM

:= P

M

(RV1 = rV1 , . . . , RVn = rVn )


(r )
(r )
UV1 ∈ DUVV1 , . . . , UVn ∈ DUVVnn .
1

For r ∈ DUCM , denote
n
(r)
(r )
DU = u : u ∈ DU , uV ∈ DUVV
15

∀V ∈ V

o

(9)
(10)

We now show that MCM and M valuate in the same way any query of the form P (φ), where^φ=
Yxi i = yii∈{1,...,k}for any Xi , Yi ⊆ V, Yi ̸= ∅, yi ∈ DYi , and positive integer k. We say M(u) |= φ for u ∈ DU if
for all i ∈ {1, . . . , k}, Yxi i (u) = yi . We define this notation similarly for MCM .
(r)

Let u1 , u2 ∈ DU be any two instantiations of U. If u1 and u2 come from the same partition DU ,then we have for all V ∈ V,fV (paV , u1V )mVnoX(r ′ )(r ′ )=hV V (paV )1 u1V ∈ DUVV
Lem. 1
′ =1
rV

(r )

= hV V (paV )mVnoX(r ′ )(r ′ )=hV V (paV )1 u2V ∈ DUVV
′ =1
rV

= fV (paV , u2V )Hence,

Lem. 1.

M(u1 ) |= φ ⇔ M(u2 ) |= φ.

(11)

(r)

Let u ∈ DU and let r ∈ DUCM . Then if u ∈ DU , we have for all V ∈ V
fV (paV , uV )mVnoX(r ′ )(r ′ )=hV V (paV )1 uV ∈ DUVV
Lem. 1
′ =1
rV

(r )

= hV V (paV )= fVCM (paV , uV )Def. 10.

Hence,
M(u) |= φ ⇔ MCM (r) |= φ.

(12)Then, by the previous statements and MCM ’s construction, we haveX
P M (φ) =P M (u){u:M(u)|=φ}(r)
P M U ∈ {DU }

X

=

(r)

{r:M(u)|=φ,u∈DU }by Eq. 11
X=

P MCM (r)(r){r:M(u)|=φ,u∈DU }by Eq. 10
X=P MCM (r){r:MCM (r)|=φ}by Eq. 12= P MCM (φ).

Lemma 2 shows that the canonical SCM can be used as a representative of equivalence classes of
SCMs. In the case where DV is discrete, the mapping from an SCM to an equivalent canonical model
conveniently also remaps DU to a discrete space. We next show that any canonical SCM can beconstructed in the form of an NCM.
16

We will focus on feedforward neural networks,
specifically multi-layer perceptrons (MLPs)
with the binary step activation function, eventhough other types of neural networks could becompatible with the statement proven here (seeAppendix D.1).
Definition 11 (Multi-layer Perceptron). A neural network node is a function defined as!
Xˆ
f (x; w, b) = σ
wi xi + b ,iwhere x is a vector of real-valued inputs, w andb are the real-valued learned weights and bias
respectively, and σ is an activation function. For
this work, we will often denote σ as the binary
step function for our activation function:

1 z≥0
σ(z) =
0 z < 0.

Figure 6: Example diagram of a neural network
node from Definition 11. Nodes on the left are inputs, numbers on the edges represent weights, andthe weighted sum of the inputs is passed throughthe binary step activation function.

This is simply one choice of activation function which always outputs a binary result. (Figure 6
provides an illustration of such a node.)
A neural network layer of width k is comprised of k neural network nodes with the same input vector,
together outputting a k-dimensional output:fˆ(x; W, b) = fˆ1 (x; w1 , b1 ), . . . , fˆk (x; wk , bk ) ,where W = {w1 , . . . , wk } and b = {b1 , . . . , bk }. An MLP is defined as a function comprised ofseveral neural network layers fˆ1 , . . . , fˆℓ , with each layer taking the previous layer’s output as its
input:fˆMLP (x) = fˆℓ (. . . fˆ1 (x; W1 , b1 ) . . . ; Wℓ , bℓ ).
This means that a neural network is a function that is a composition of the functions of the individual
layers, where the input is the input to the first layer, and the output is the output of the last layer. ■We will show next three basic lemmas (3-5) that will be used later on to help understand theexpressiveness of the networks introduced from Def. 11.
Lemma 3. For any function f : X → Y mapping a set of binary variables to a binary variable,
there exists an equivalent MLP fˆ using binary step activation functions.
■
Proof. We define the following three neural network components:• Given binary input x, with w = −1 and b = 0, neural network functionfˆNOT (x) = σ(−x)
outputs the negation of x.
• Given binary vector input x, with w = 1 and b = −1, neural network function!
X
fˆOR (x) = σ
xi − 1i

outputs the bitwise-OR of x.
• Given binary vector input x, with w = 1 and b = −|x|, neural network function!
XˆfAND (x) = σ
xi − |x|i

outputs the bitwise-AND of x.
17

Since all functions mapping a set of binary variables to a binary variable can be written in disjunctive
normal form (DNF), we can combine these three components to build fˆ.
Lemma 4. For any function f : X → Y mapping set of variables X to variable Y , all from finite
numerical domains, there exists an equivalent MLP fˆ using binary step activations.
■
Proof. For each value x ∈ DX , we first aim to assign a unique binary representation bin(x), which
we can use more flexibly due to Lemma 3. One simple way to accomplish this is to map the values toa one-hot encoding, a binary vector for which each element corresponds to a unique value in DX .
We will use here a neural function with w = 1 and b = −z, so we havefˆ≥z (x) = σ(x − z)which, on input x, outputs 1 if x ≤ z or 0 otherwise. We will also borrow the binary functions fromthe proof of Lem. 3.
For each Xi ∈ X and each xi ∈ DXi , we construct neural network functionfˆ=xi (x) = fˆAND fˆ≤xi (x), (∀x′i < xi )fˆNOT fˆ≤x′i (x)where x′i ∈ DXi , which, on input x ∈ DXi , outputs 1 if x = xi or 0 otherwise.
We can then define for each z ∈ DX
fˆ=z (x) = fˆAND ∀ifˆ=zi (xi )
which, on input x ∈ DX , outputs 1 if x = z or 0 otherwise. Here, xi and zi denote the ith element ofx and z respectively.
We can then define an one-hot binary representation of x, bin(x), to be a vector of the outputs offˆ=z (x) for all z ∈ DX :fˆENC (x) = ∀(z ∈ DX )fˆ=z (x)This representation is a binary vector of length |DX | and is unique for each value of x ∈ DX becausefˆ=z (x) = 1 if and only if x = z, so a different bit is 1 for every choice of x.
We can similarly define a binary representation for each y ∈ DY , bin(y), as a binary vector of length|DY |, where each bit corresponds to a value in DY . If yi ∈ DY is the value that corresponds with
the ith bit of bin(y), then bin(y)i = 1 if and only if y = yi . Now we consider the translation frombin(y) back into y using neural networks. We can create the neural network function on input bin(y)with w = (yi : yi ∈ DY ) and b = 0,fˆDEC (bin(y)) = w⊺ bin(y),omitting the binary step activation function σ. This function simply computes the dot product ofbin(y) with a vector of all of the possible values of Y , which results in y since bin(y) is 0 in every
location except for the bit corresponding to y.
Combining all of these constructed neural network functions, we can construct a final MLP fˆ formapping X to Y :1. On input x ∈ DX , convert x to bin(x) using fˆENC (x).
2. By Lemma 3, find some MLP mapping bin(x) to bin(y).
3. Finally, use fˆDEC to convert bin(y) to y.
The final MLP fˆ is the composition of all of the neural networks used to realize these three steps.
Although neural networks as defined in Def. 11 are undefined for non-numerical inputs and outputs,
any kind of categorical data can be considered if first converted into a numerical representation.
The above two lemmas show that MLPs can be used to express any function, but we will need anotherresult to incorporate the exogenous sources of randomness. Specifically, we show that MLPs canmap Unif(0, 1) noise to any other distribution of variables.
18

Lemma 5 (Neural Inverse Probability Integral Transform (Discrete)). For any probability massfunction P (X), there exists an MLP fˆ which maps Unif(0, 1) to P (X).
■
Proof. Let x1 , x2 , . . . be the elements of the support of P (X), ordered arbitrarily. We also definesome arbitrary x0 such that P (x0 ) = 0. For each i ∈ {0, 1, 2, . . . }, construct neural network
Pifunction, with w = 1 and b = − j=0 P (xj )iXfˆxi (u) = σ u −P (xj )j=0

Pi

which, on input u, returns 1 if and only if u ≥ j=0 P (xj ). Note that fˆx0 (u) is always 1. We
then construct a neural network function fˆOUT which, on inputs (fˆx0 , fˆx1 , fˆx2 , . . . ), outputs one ofx1 , x2 , . . . . Specifically, it operates as follows:
1. For each i ∈ {1, 2, . . . }, if fˆxi = 0 and fˆxi−1 = 1, then output xi .
2. If none hold, output any arbitrary xi (this will never happen).
By Lemma 4, we can construct such a function since all fˆxi are binary. Then, let ĝ(u) =fˆOUT (fˆx0 (u), fˆx1 (u), fˆx2 (u), . . . ). Observe that for u sampled from Unif(0, 1),P (ĝ(u) = xi ) = P fˆOUT fˆx0 (u), fˆx1 , fˆx2 , . . . = xi
= P fˆxi (u) = 0 ∧ fˆxi−1 (u) = 1


i
i−1
X
X
= P u <P (xj ) ∧ u ≥P (xj )
j=0

j=0



i−1
i
X
X
=P
P (xj ) ≤ u <P (xj )
j=0

=

i
X

j=0

P (xj ) −

j=0

i−1
X

P (xj )

j=0

= P (xi )for each i ∈ {1, 2, . . . }. Therefore, we see that ĝ successfully maps the Unif(0, 1) distribution to
P (X).
We can now combine these neural network results with the canonical SCM results to complete theexpressiveness proof for NCMs.
Theorem 1 (NCM Expressiveness). For any SCM M∗ = ⟨U, V, F, P (U)⟩, there exists an NCM
b V, F,b s.t. Mc(θ) = ⟨U,b P (U)⟩c is L3 -consistent w.r.t. M∗ .
M■
Proof. Lemma 2 guarantees that there exists a canonical SCM MCM = ⟨UCM , V, FCM , P (UCM )⟩c, it suffices to show how to construct MCM
that is L3 -consistent with M∗ . Hence, to construct M
using the architecture of an NCM.
b = {UbV }. For each Vi ∈ V, we construct fˆV ∈ Fb
Following the structure of Def. 3, we choose U
iusing the following components:
1. By Lemma 5, construct fˆVRi : DUbV → DUCM such thatwherefˆVRi (buV ) = uCM ,

(13)



c
bV ) = uCM = P MCM (uCM ).
P M fˆVRi (U

(14)

19

2. By Lemma 4, construct fˆVHi : DPaVi × DUCM → DVi such thatfˆVHi (paVi , uCM ) = fVCM
(paVi , rVi )i(r )= hViV (paVi )

(15)
(16)

where rVi is the value in uCM corresponding to Vi .
Combining these two components leads to MLPuV )bV ) = fˆVHi paVi , fˆVRi (bfˆVi (paVi , u(17)Although this does not exactly fit the structure in Def. 11 because paV is not included as an input intofˆVRi , this can be altered by simply having fˆVRi accepting paV as an input and outputting it alongside
uCM without changing it.
c is constructed to match MCM on all outputs. Hence, for any
By Eqs. 14 and 16, the NCM M
counterfactual query φ, we havec |= φMCM |= φ ⇔ M
and thereforec |= φ.
M∗ |= φ ⇔ M

While Thm. 1 demonstrates the expressive power of an SCM parameterized by neural networks,
we now consider its limitations. Notably, we show in the sequel that NCMs suffer from the sameconsequences implied by the CHT.
Fact 1 (Causal Hierarchy Theorem (CHT) [5, Thm. 1]). Let Ω∗ be the set of all SCMs. We saythat Layer j of the causal hierarchy for SCMs collapses to Layer i (i < j) relative to M∗ ∈ Ω∗
if Li (M∗ ) = Li (M) implies that Lj (M∗ ) = Lj (M) for all M ∈ Ω∗ . Then, with respect to theLebesgue measure over (a suitable encoding of L3 -equivalence classes of) SCMs, the subset in which
Layer j of NCMs collapses to Layer i is measure zero.
■
We prove a similar result for NCMs as a corollary of Fact 1 and Thm. 1.
Corollary 1 (Neural Causal Hierarchy Theorem (N-CHT)). Let Ω∗ and Ω be the sets of all SCMs
and NCMs, respectively. We say that Layer j of the causal hierarchy for NCMs collapses to Layer ic) implies that Lj (M∗ ) = Lj (Mc) for all Mc ∈ Ω.
(i < j) relative to M∗ ∈ Ω∗ if Li (M∗ ) = Li (MThen, with respect to the Lebesgue measure over (a suitable encoding of L3 -equivalence classes of)
SCMs, the subset in which Layer j of NCMs collapses to Layer i has measure zero.
■
Proof. Since all NCMs are SCMs, an SCM-collapse with respect to M∗ also implies an NCMcollapse with respect to M∗ .
If layer j does not SCM-collapse to layer i with respect to M∗ , then there exists an SCM M suchthat Li (M∗ ) = Li (M) but Lj (M∗ ) ̸= Lj (M). By Thm. 1, this implies that there exists an NCM
c such that Li (M∗ ) = Li (M)c but Lj (M∗ ) ̸= Lj (M),c which means that layer j also does notM
NCM-collapse to layer i.
These two statements imply that the set of SCMs that undergo some form of SCM-collapse isequivalent to the set of SCMs that undergo some form of NCM-collapse. Therefore, the result from
Fact 1 must also hold for NCMs.
A.2

Proof of Theorem 2

The results proven in this section involve the incorporation of structural constraints, as introduced
through the graphical treatment provided in [57], and made it explicit and generalized for models
with latent variables in [5, Sec.1. 4]. For convenience, we list the basic definitions below, but refer
the readers to the references for more detailed explanations and further examples.
Definition 12 (Causal Diagram [5, Def. 13]). Consider an SCM M = ⟨U, V, F, P (U)⟩. We
construct a graph G using M as follows:20

(1) add a vertex for every variable in V,(2) add a directed edge (Vj → Vi ) for every Vi , Vj ∈ V if Vj appears as an argument offVi ∈ F,(3) add a bidirected edge (VjVi ) for every Vi , Vj ∈ V if the corresponding UVi , UVj ⊆ U
are not independent or if fVi and fVj share some U ∈ U as an argument.
We refer to G as the causal diagram induced by M (or “causal diagram of M” for short).
■
Definition 13 (Confounded Component [5, Def. 14]). Let G be a causal diagram. Let{C1 , C2 , . . . , Ck } be a partition over the set of variables V, where Ci is said to be a confounded
component (C-component for short) of G if for every Va , Vb ∈ Ci , there exists a path made entirely of
bidirected edges between Va and Vb in G, and Ci is maximal. We denote C(Va ) as the C-component
containing Va .
■Definition 14 (Semi-Markov Relative [5, Def. 15]). A distribution P is said to be semi-Markov
relative to a graph G if for any topological order < of G through its directed edges, P factorizes asY
P (v) =
P (vi | pa+
(18)
Vi ),
Vi ∈V

where Pa+■
Vi = Pa({V ∈ C(Vi ) : V ≤ Vi }), with ≤ referring to the topological ordering.
Definition 15 (Causal Bayesian Network (CBN) [5, Def. 16]). Given observed variables V, let P∗ be
the collection of all interventional distributions P (V | do(x)), X ⊆ V, x ∈ DX . A causal diagram
G is a Causal Bayesian Network for P∗ if for every intervention do(X = x) and every topologicalordering < of GX through its directed edges,(i) P (V | do(X = x)) is semi-Markov relative to GX .
(ii) For every Vi ∈ V \ X, W ⊆ V \ (PaX+∪ X ∪ {Vi }):ix+
P (vi | do(x), pax+i , do(w)) = P (vi | do(x), pai ),(iii) For every Vi ∈ V \ X, let PaX+
be partitioned into two sets of confounded and unconi
founded parents, Paci and Paui in GX . ThenP (vi | do(x), paci , do(paui ))= P (vi | do(x), paci , paui )Here, Pax+
Vi = Pa({V ∈ CX (Vi ) : V ≤ Vi }), with CX referring to the corresponding C-component
in GX and ≤ referring to the topological ordering.
■
In fact, for any SCM M, its induced causal diagram and interventional distributions form a CBN. Thismeans that the diagram encodes the qualitative constraints induced over the space of interventional
distributions, despite the specific values that these distributions attain and the F and P (U) of M.
Fact 2 (SCM-CBN L2 connection [5, Thm. 4]). The causal diagram G induced by SCM M is a CBN
for L2 (M).
■We can now show that, indeed, all of the CBN constraints implied by a causal diagram G are encoded
in a G-constrained NCM constructed via Def. 7.
b V, F,b be a G-constrained NCM. Let Gb be the causal diagramc(θ) = ⟨U,b Pb(U)⟩
Lemma 6. Let M
cb
induced by M . Then G = G.
■b construction, note that by step 1 all of the vertices
Proof. Considering Def. 12 in the context of G’smatch, simply having one for each variable in V.
Step 2 adds a directed edge from Vi to Vj if fˆVi has Vj as an argument. By step 2 of Def. 7, paVj
will contain Vi if and only if there was a directed edge from Vi to Vj in G. This implies that fˆV willj

21

contain Vi as an argument if and only if there was a directed edge from Vi to Vj in G, so the directedbedges must also match in G.
Finally, step 3 of Def. 12 states that a bidirected edge between Vi and Vj is added to Gb when fˆVi andb that are not independent. Def. 3
b as an argument or have arguments from Ub ∈UfˆVj share some Ubbb
ensures that all variables in U are independent, so a shared U ∈ U between functions in Fb is the onlyb Step 1 of Def. 7 constructs Ub such that it contains
way a bidirected edge would be generated in G.
bC if and only if C is a C 2 -component in G. If Vi , Vj ∈ V are connected by a bidirected edge
some Uin G, then there must exist some C 2 -component C in G such that Vi , Vj ∈ C∗ , so there must existb Hence, since U
bC ∈ U.
bC is shared by both fˆV and fˆV , the corresponding bidirected edge in GUijbmust also match in G.
b we can conclude that G = G.
b
Therefore, since all vertices and edges match between G and G,c(θ) is G-consistent.
Theorem 2 (NCM G-Consistency). Any G-constrained NCM M■

Proof. This follows directly from Lemma 6 and Fact 2.
A.3

Proof of Theorem 3

For this proof, we expand on the technical results provided in Zhang et al. [73]. The paper works
with a subclass of SCMs known as discrete SCMs and proves strong results about its expressiveness.
Similar to this paper, we will assume that in any SCM, the variables in U are independent, andunobserved confounding is modeled by sharing the same variable from U in the functions of multiple
variables in V.
Definition 16 (Discrete SCM [73, Def. 2]). An SCM M = ⟨U, V, F, P (U)⟩ is said to be a discrete
SCM if DU is discrete for all U ∈ U and DV is both discrete and finite for all V ∈ V.
■
Fact 3 ([73, Thm. 1]). Let Ω∗ be the set of all SCMs and Ω′ the set of discrete SCMs. For any SCM
M∗ ∈ Ω∗ inducing causal diagram G, there exists a discrete SCM M′ ∈ Ω′ with finite |DU | for all
U ∈ U such that M′ is G-consistent and is L3 -consistent with M∗ .
■We can now combine these results to achieve an expressiveness result on the counterfactual level for
NCMs.
Theorem 3 (L2 -G Representation). For any SCM M∗ that induces causal diagram G, there exists ab V, F,b that is L2 -consistent w.r.t. M∗ .
c(θ) = ⟨U,b P (U)⟩
G-constrained NCM M■
Proof. By Fact 3, there must exist a discrete SCM M′ = ⟨U′ , V, F ′ , P (U′ )⟩ such that M′ isG-consistent, is L3 -consistent with M∗ (implying L2 -consistency), and |DU | is finite for all U ∈ U.
b V, F,b be a G-NCM such that each fˆV ∈ Fb is an MLP composed of smallerc = ⟨U,b P (U)⟩
Let M
MLPs as defined next.
For U ∈ U′ , let VU ⊆ V denote the set of endogenous variables such that for all V ∈ VU , fˆV takes
U as an argument. Let C = {C1 , . . . , Ck }, with C1 , . . . Ck ⊆ V denote the set of C 2 -componentsof G. Let U′C1 , . . . , U′Ck be a partition over U′ such that if U ∈ U′Ci , then VU ⊆ Ci . If for any
U ∈ U′ , there exist multiple components such that this applies, one can be chosen arbitrarily. For
each V , let C(V ) ⊆ C denote the set of components that contain V . Then we note that
[
U′V ⊆
U′C ,
C∈C(V )

where U′V ⊆ U′ denotes the exogenous parents of V in M′ .
b consists of a Unif(0, 1) random variable U
bC for each C 2 By construction of the G-NCM in Def. 7, U
i′(U)
bC to U′ for each Ci . Thencomponent Ci . By Lemma 5, we can construct MLP fˆCi mapping UiCi(F ′ )by Lemma 4, we can construct MLP fˆ
to map U′ and PaV to V , matching f ′ . Combining
V

V

22

V

(F ′ )b V ) is defined as fˆVthese two results, fˆV (paV , u

(U′ )

(U′ )

1

ℓ

(paV , fˆCi (buCi1 ), . . . , fˆCi (buCiℓ )), whereC(V ) = {Ci1 , . . . , Ciℓ }. 11
′

′
(U )
b to U′ , andAltogether, Fb(U ) = {fˆC : C ∈ C} collectively forms a neural mapping from U′′(F)
Fb(F ) = {fˆV
: V ∈ V} collectively forms a neural mapping from U′ to V. We use the notation
Fx (U) |= y to be equivalent to the statement Yx (U) = y, which is the random event (w.r.t. U) thatthe variables of Y under intervention X = x takes value y.

Then, for any interventional query Q = P (y | do(x)) = P (Yx = y), we havecb x (U)b =y
P M (y | do(x)) = P Yb |= y= P Fbx (U)




′
′
b |= y= P Fbx(F ) Fb(U ) (U)′= P Fbx(F ) (U′ ) |= y
= P (Fx′ (U′ ) |= y)= P (Yx′ (U′ ) = y)′

= P M (y | do(x))∗= P M (y | do(x)).
Hence, we have shown that for any SCM M∗ inducing causal diagram G, we can construct a G-NCM
that matches M∗ on the second layer.
A.4

Proofs of Theorem 4 and Corollaries 2 and 4

Theorem 4 (Graphical-Neural Equivalence (Dual ID)). Let Ω∗ be the set of all SCMs and Ω the set of
NCMs. Consider the true SCM M∗ and the corresponding causal diagram G. Let Q = P (y | do(x))
be the query of interest and P (V) the observational distribution. Then, Q is neural identifiable fromΩ(G) and P (V) if and only if it is identifiable from G and P (V).
■Proof. Since Ω ⊂ Ω∗ , it must be the case that identifiability in G and P (V) implies identifiability inΩ(G) and P (V). Identifiability in G and P (V) implies that all pairs of SCMs that match in G and
P (V) will also match in Q. This means that for any SCM M∗ that induces P (V) and G, we musthave P M1 (y | do(x)) = P M2 (y | do(x)) for all pairs of SCMs M1 , M2 ∈ Ω∗ that induce G suchthat L1 (M1 ) = L1 (M2 ) = P (V). Given that all NCMs are SCMs, and G-constrained NCMs are
G-consistent by Thm. 2, the set of all G-consistent SCMs includes the set of all G-constrained NCMs.
Hence, this match in Q should also hold if M1 and M2 are NCMs.
If Q is not identifiable from G and P (V), there must exist M1 , M2 ∈ Ω∗ such that M1 and M2
both induce G, L1 (M1 ) = L1 (M2 ) = P (V) > 0, but P M1 (y | do(x)) ̸= P M2 (y | do(x)).
c1 , Mc2 ∈ Ω(G) such that L2 (Md1 ) = L2 (M1 )Theorem 3 states that there must exist NCMs M∗
dand L2 (M2 ) = L2 (M2 ). This implies that, for any SCM M inducing G and observational
distribution P (V), there exist these two G-constrained NCMs that are L1 -consistent with M∗(since they are L2 -consistent with M1 and M2 respectively), yet they do not match in Q (i.e.
ccP M1 (y | do(x)) ̸= P M2 (y | do(x))). In other words, if Q is not identifiable from G and P (V), thenit is also not identifiable from Ω(G) and P (V).
S
There are a few subtleties here to align with Def. 11. First, although C∈C(V ) U′C may contain elements′(F )of U′ not in U′V , fˆV
can be constructed to accept them as input and not use them (weight of 0, identity
activation function). Secondly, although Def. 11 does not allow additional inputs inbetween layers, paV can(U′ )simply be provided as an input to fˆC and passed forward to the next layer without modification (weight of 1,
identity activation function). Thirdly, while Def. 11 is not defined to have multiple nested MLPs in the samelayer, the same result can be achieved by nesting them iteratively and passing the relevant outputs through thenested layers without modification. The presentation in the proof is made for the sake of clarity.
11

23

Corollary 2 (Neural Mutilation (Operational ID)). Consider the true SCM M∗ ∈ Ω∗ , causal∗
diagram G, the observational distribution P (V), and a target query Q equal to P M (y | do(x)).
c ∈ Ω(G) be a G-constrained NCM that is L1 -consistent with M∗ . If Q is identifiable from G
Let M
c, i.e., for eachand P (V), then Q is computable through a mutilation process on a proxy NCM Mc
X ∈ X, replacing the equation fx with a constant x (Q = PROC - MUTILATION(M ; X = x, Y)). ■c′ ∈ Ω(G) such that M
c′ is L2 -consistent
Proof. By Thm. 3, there must exist a G-constrained NCM M′∗
cc′ is L1 -consistent with M∗ and P M
with M∗ , implying that M(y | do(x)) = P M (y | do(x)).
By Thm. 4, since Q is identifiable from G and P (V), it must be also be identifiable from Ω(G) andP (V). This means that all G-constrained NCMs that agree on P (V) must also agree on Q with eachcc′other, so it must be the case that P M (y | do(x)) = P M (y | do(x)) for any other G-constrained∗cc ∈ Ω(G) such that L1 (Mc) = P (V). This means that P M
NCM M(y | do(x)) = P M (y | do(x))
cc that match P (V). Finally, P M
for arbitrary G-constrained NCMs M(y | do(x)) can be computedc using Def. 2.
from M
Corollary 4 (Soundness and Completeness). Let Ω∗ be the set of all SCMs, M∗ ∈ Ω∗ be the true
b be the result from
SCM inducing causal diagram G, Q = P (y | do(x)) be a query of interest, and Q
running Alg. 1 with inputs P ∗ (V) = L1 (M∗ ) > 0, G, and Q. Then Q is identifiable from G andb is not FAIL. Moreover, if Q
b is not FAIL, then Q
b = P M∗ (y | do(x)).
P ∗ (V) if and only if Q■
Proof. Theorem 4 states that Q must be identifiable from G and P ∗ (V) if and only if for all pairs of
c1
c1 , Mc2 ∈ Ω(G) with L1 (Mc1 ) = L1 (Mc2 ) = P ∗ (V) > 0, P M
G-consistent NCMs, M(y | do(x)) =
c ∗
c ∗
c
P M2 (y | do(x)). This holds if and only if P M (θmin ) (y | do(x)) = P M (θmax ) (y | do(x)). If theyc(θ ∗ ) and Mc(θ ∗ ) are a counterexample of two NCMs that do not match
are not equal, then M
maxminfor Q. Otherwise, if they are equal, then all other NCMs must also induce the same answer for Q.
c ∗c ∗A result for Q that is less than P M (θmin ) (y | do(x)) or greater than P M (θmax ) (y | do(x)) would∗∗
contradict the optimality of θminand θmax.
If Q is identifiable, then Corollary 2 guarantees that any NCM that induces P ∗ (V) and G will induce∗
the correct P M (y | do(x)).
A.5

Proof of Corollary 3

In our discussion of the identification problem in Sec. 3, we stated Corol. 3 as the solution to a specialclass of models known as Markovian. In SCMs, Markovianity implies that all variables in U areb of
independent and not shared between functions. Correspondingly, this means that no variable in U
an NCM can be associated with more than one function. In the causal diagram, this implies that there
are no bidirected edges.
We emphasize that Markovianity is a strong constraint in many settings, and the following corollary
from [5] illustrates that identification in the Markovian setting is quite trivial.
Fact 4 ([5, Corol. 2]). In Markovian models (i.e., models without unobserved confounding), for any
treatment X and outcome Y, the interventional distribution P (Y | do(x)) is always identifiable andgiven by the expression
X
P (Y | do(x)) =P (Y | x, z)P (z),(19)
zwhere Z is the set of all variables not affected by the action X (non-descendants of X).

■

In other words, every query in a Markovian setting can be identified via Eq. 19, also known as the
backdoor adjustment formula. Naturally, this result extends to identifiability via mutilation in NCMs
due to the connection between neural identification and graph identification.
c is Markovian, P (y |Corollary 3 (Markovian Identification). Whenever the G-constrained NCM M
do(x)) is always identifiable through the process of mutilation in the proxy NCM (via Corol. 2). ■24

Proof. Fact 4 shows that any query P (y | do(x)) is identifiable from G and P (v) in Markovian
settings. Hence, by Thm. 4, it must also be identifiable from Ω(G) and P (v). Moreover, Corol. 2
states that the effect can be computed via the mutilation procedure on a proxy G-constrained NCM
c with L1 (Mc) = P (v).
M

Without the Markovianity assumption, the identification problem becomes significantly more challenging. As we show in Example 2 from Appendix C.1, a query can be non-ID even in a two variablecase whenever unobserved confounding cannot be ruled out.

A.6

Derivation of Results in Section 4

Recall the description of our choice of NCM architecture from Eq. 2:



V



Fb

b := {UC : C ∈ C 2 (G)} ∪ {GV : Vi ∈ V},:= V, U ilog σ(ϕVi (paVi , ucVi ; θVi )):= fVi := arg maxj∈{0,1} gj,Vi +log(1 − σ(ϕVi (paVi , ucVi ; θVi )))b
P (U) := {UC ∼ Unif(0, 1) : UC ∈ U} ∪
{Gj,Vi ∼ Gumbel(0, 1) : Vi ∈ V, j ∈ {0, 1}},

j=1
j=0


,

(2)

Using this architecture, we show the derivation of Eq. 3, starting with sampling from P (v). Let Uc
and G denote the latent C 2 -component variables and Gumbel random variables [24], respectively.
The formulation in Eq. 2 allows us to compute the probability mass of a datapoint v as:
P M (G;θ) (v)= E [1[F(u) = v]]
c

P (u)

"
=

Y

E

P (uc )P (g)#
1 fVi (paVi , uVi ) = vi

Vi ∈V

"
=

E

P (uc )#
Yσ̃vi (ϕi (paVi , ucVi ; θVi ))

,

(20)

Vi ∈V



σ(x)
vi = 1. We can then derive a Monte Carlo estimator given samples
1 − σ(x) vi = 0c{ucj }mj=1 ∼ P (U ):where σ̃vi (x) :=m

M (G;θ)
P̂m
(v) =
c

1 X Y
σ̃vi (ϕVi (paVi , ucj,Vi ; θVi )).
m j=1

(21)

Vi ∈V

One may similarly estimate the interventional query, P (y|do(x)), where y, x are the values of thecvariable sets Y, X ⊆ V. We first compute an estimable expression for P M (y|do(x)):
25

P M (G,θ) (y|do(x))
Xc=P M (v|do(x))
c

V\(Y∪X)





= E 
P (u)

1 [Fx (u) = v]

X

V\(Y∪X)=X

E

P (uc )P (g)

Y



i

V\(Y∪X) Vi ∈V\X


=


X

E 

P (uc )



1 fVi (paV , uVi ) = vi Yσ̃vi (ϕVi (paVi , ucVi ; θVi )) .

(22)

V\(Y∪X) Vi ∈V\X

The interventional distribution may be similarly estimated. We derive a Monte Carlo estimator for thecabove expression using a submodel of the NCM under do(X = x) given samples {ucj }mj=1 ∼ P (U ):M (G,θ)Pm(y|do(x))
m
1 X X
=
m j=1
c

Y

σ̃vi (ϕVi (paVi , ucj,Vi ; θVi )).

(23)

V\(Y∪X) Vi ∈V\X

The implementation of Eq. 3 can be summarized in Alg. 3, which defines the “Estimate” functionused in Alg. 2.
Algorithm 3: Estimate P M (v | do(x)) (Eq. 3)
c, variables V in topological order, v ∈ DV , intervention set X ⊂ V, x ∈ DX ,Input : NCM M
number of Monte Carlo samples mc
Output : estimate of P M (v | do(x))
c

if not Consistent(v, x) then return 0b c ))
b c1:m ← Sample(P (Uu
3 p̂ ← 0
4 for j ← 1 to m do
5p̂j ← 1
6for i ← 1 to |V| do
7
if Vi ̸∈ X then8p̂j ← p̂j σv′ i (ϕVi (paVi , ucj,Vi ; θVi ))12p̂ ← p̂ + p̂j

910// From Eq. 3p̂
return m

B

Experimental Details

This section provides the detailed information about our experiments. Our models are primarily
written in PyTorch [55], and training is facilitated using PyTorch Lightning [16].
B.1

Data Generation Process

The NCM architecture follows the description in Eq. 2. For each function, we use a MADE module[18] following the implementation in [36] (MIT license). Each MADE module uses 4 hidden layers ofsize 32 with ReLU activations. For each complete confounded component’s unobserved confounder,26

we use uniform noise with dimension equal to the sum of the complete confounded component’s
variables’ dimensions.
To generate data for our experiments, we use a version of the canonical SCM similar to Def. 10. Given
data from P (V) and a graph G, we construct a canonical SCM MCM = ⟨UCM , V, FCM , P (UCM )⟩such that for each V ∈ V, paV contains the set of variables with a directed edge into V in G. For
any bidirected edge between V1 and V2 , we introduce a dependency between the noise generated
from RV1 and RV1 . Otherwise, variables in UCM are independent.
The canonical SCM is implemented in PyTorch, with trainable parameters that determine P (UCM ).
In an experiment trial, we create true model M∗ , which is an instantiation of a canonical SCM withrandom parameters. Unlike cases where M∗ comes from a set family of SCMs, which may produce
biased results, the expressiveness of the canonical SCM allows us to robustly sample data generating
models that can take any behavior consistent with the constraints of G.
In the estimation experiments, to make things more challenging, we take one additional step after
constructing M∗ in cases where P (Y | do(X)) is not necessarily equal to P (Y | X). To ensure that
this inequality holds, we widen the difference between ATE and total variation (TV), computed inthis case as P (Y = 1 | X = 1) − P (Y = 1 | X = 0). We accomplish this by performing gradientdescent on the parameters of the canonical SCM until this difference is at least 0.05.
From the perspective of simulating the ground truth, sampling from the canonical SCM can beaccomplished using the same procedure from Def. 2.
B.2

Identification Running Procedure

For the identification experiments, we test on the 8 graphs shown in the top of Fig. 4. For each graph,
we run 20 trials, each repeated 4 times on the same dataset for the sake of hypothesis testing.
For each trial, we create a canonical SCM from the graph G for the data generating model M∗ . We
sample 10,000 data points from P (V), where V is determined by the nodes in G, each being a binary
variable.
cmin and M
cmax , and train them on the given data using
With G as input, we instantiate two NCMs, M
a PyTorch Lightning trainer. Both models are trained for 3000 epochs using the minimization andmaximization version of the objective in Eq. 5, respectively. λ is initialized to 1 at the beginning oftraining and decreases logarithmically throughout training until it reaches 0.001 at the end.
We use the AdamW optimizer [51] with the Cosine Annealing Warm Restarts learning rate scheduler[50]. When using Eq. 3 to compute probabilities, we choose m = 20000.
We log the ATE of both models every 10 iterations and use it to compute the max-min gaps from thel.h.s. of Eq. 6. The gaps from each trial are averaged across the 4 runs. The percentiles of these gaps
over the 20 trials are plotted across the 3000 epochs in the bottom row of Fig. 4. We use these gaps
in the hypothesis testing procedure described later in Sec. B.4 with τ = 0.01, 0.03, 0.05 and plot
the accuracy over the 20 trials in the middle row of Fig. 4. For smoother plots, we use the runningaverage over 50 iterations.
To ensure reproducibility, each run’s random seed is generated through a SHA512 encoding of a key.
The key is determined by the parameters of the trial such as the graph, the number of samples, andthe trial index.
The NCMs are trained on NVIDIA Tesla V100 GPUs provided by Amazon Web Services. In total,
we used about 150 GPU hours for the identification experiments.
B.3

Estimation Running Procedure

For the estimation experiments, we test on the 4 identifiable graphs at the top of Fig. 4. For eachgraph, we test 15 different amounts of sample data, ranging from 103 to 106 on a logarithmic scale.
Each setting is run for 25 trials.
For each trial, we create a canonical SCM from the graph G for the data generating model M∗ . We
sample the data from P (V), where V is determined by the nodes in G, each being a binary variable.
27

c, given G, and we train it on the given data using a PyTorch Lightning
We instantiate an NCM, M
trainer. The model is trained using the objective in Eq. 4. We incorporate early stopping, where
the model ends training if loss does not decrease by a minimum of 10−6 within 100 epochs. After
training, the parameters of the best model encountered during training are reloaded.
We use the AdamW optimizer [51] with the Cosine Annealing Warm Restarts learning rate scheduler[50]. When using Eq. 3 to compute probabilities, we choose m = 1.6 × 106 .
For each trial, we save the training data and perform the same estimation experiment with thenaïve likelihood maximization model and WERM [33]. The naïve model is also optimized with theobjective in Eq. 4 to fit P (V). Since code for WERM is not available, we implement our own version
in Python trying to match the code provided in the paper. Notably, we use XGBoost [12] regressors
trained on the data to learn the WERM weights. These regressors are chosen with 20 estimators anda max depth of 10. They are trained with the binary logistic objective for binary outputs, otherwise
they are trained using the squared error objective. The regularization parameter λWERM (not to be
confused with the λ in Eq. 5) is learned through hyperparameter tuning, checking every value from 0
to 10 in increments of 0.2. The regularization parameter αWERM is set to λWERM /2.
We record the KL divergence of the best models of the NCM and naïve models after training,
computed as
!
∗


X
P M (v)
c
M∗
M
M∗
DKL P
(V)||P (V) =P(v) log
.
c
PM
(v)
v∈DV
The mean and 95%-confidence intervals of the KL divergence across the 25 trials are plotted overeach setting of sample size in the top row of Fig. 5.
We also record the ATE computed from all three methods after training. In the case of the naïve
model, we use TV as the ATE calculation. For the NCM and naïve model, we use the sampling
procedure described in Eq. 3 with m = 106 to compute these results. The mean and 95%-confidence
intervals of the ATE computations across the 25 trials are plotted over each setting of sample size inthe bottom row of Fig. 5.
Randomization is performed similarly to the identification experiments.
The NCMs and naïve models are trained on NVIDIA Tesla V100 GPUs provided by Amazon Web
Services. In total, we used about 300 GPU hours for the estimation experiments.
B.4

Identification Hypothesis Testing

We incorporate a basic hypothesis testing procedure to test the inequality in Eq. 6. In each trialof the identification experiments, we rerun the procedure on the same dataset r times (r = 4 inb denote the random variable representing the max-min gap from a run
our experiments). Let ∆Qin a specific trial, and let {∆q̂i }ri=1 denote the empirical set of max-min gaps from all r runs. Theb arises from the randomness of parameter initialization in the NCM. ∆Q
b israndomness in ∆Q
not necessarily normally distributed, but we assume that the mean of {∆q̂i }ri=1 will be normally
distributed given a large enough r due to the central limit theorem.
b < τ with the null hypothesis that E[∆Q]b ≥ τ . We
For a given τ , we test the hypothesis that E[∆Q]
estimaterXb ≈ ∆q̂ := 1E[∆Q]∆q̂i ,
r i=1
the mean of the empirical set of gaps. Then we compute the standard error
v
u r
X

1u
∆q̂i − ∆q̂ .
SE(∆q̂) := tr i=1Finally, we check∆q̂ + 1.65 SE(∆q̂) < τ.
28

Figure 7: Example plots aggregating max-min gaps across multiple settings. Left is ID, right isnonID. Bottom plots are zoomed versions of top plots. Dashed lines represent choices of τ at 0.01
(red), 0.03 (green) and 0.05 (blue).

If this quantity holds, we reject the null hypothesis with 95% confidence, and we return the result thatthe query is identifiable. If not, we fail to reject the null hypothesis and we return the result that thequery is not identifiable.
We showed the results of three different values of τ
(0.01, 0.03, 0.05) in Fig. 4 (main paper). Here, we try
to understand how τ can be determined more systematically by running a preliminary round of identification experiments and observing the percentiles of theresulting gaps; see Fig. 7. Note that most gaps in the
ID case fall below the 0.03 line by the end of training process, while most gaps in the nonID case stay
above it. This can be used to motivate a particular
choice of τ .
Figure 8: NCM estimation results for ID
graphs when setting the number of observed
To demonstrate the potential of NCMs to scale to samples to 1000000 and the number of dilarger settings, we provide additional estimation re- mensions for each multi-dimensional binary
sults on higher dimensional data in Fig. 8. We use covariate (any variable which is not X or Y )the same canonical SCM architecture but probabilis- to 20. The graphs displayed in the plot corretically map the value of each binary variable which is spond to the same graphs as a, b, c, d in Fig. 4.
not X or Y to a 20-dimensional binary vector, such Plot in log scale.
that there exists a deterministic mapping from each covariate’s 20-dimensional binary vectors to theoriginal binary value (that is, the original binary value is recoverable from the 20-dimensional mapped
vector). This preserves ATE and TV while increasing the difficulty of the NCM’s optimization problem by testing the NCM’s ability to learn in high-dimensional spaces. In this more challenging
high-dimensional setting, the NCM maintains superior or equal performance when compared to
WERM.
B.5

Additional Results

29

B.6

Other Possible Architectures

In Sec. 4, we provided one possible architecture of the NCM (Eq. 2), which produced the empiricalresults discussed in Sec. 5. These results show that, in principle, training a proxy model can be used
to solve the identification and estimation problems in practice.
Still, other architectures may be more suitable and perform more efficiently than the one shownin Eq. 2 in larger, more involved domains. In such settings, it may be challenging to match the
distributions well enough to reach the correct identification result, or to lower the error on estimating
the query of interest. While Corol. 4 guarantees the correct result with perfect optimization, this israrely achieved in practice. It’s certainly not fully understood how optimization errors on the learningof P (V) will affect the performance of identification/estimation of Layer 2 quantities.
Naturally, the framework developed here to support proxy SCMs is not limited to the architecture in
Eq. 2. For instance, as discussed in Footnote 9, there are alternative methods of learning P (V) such as
by minimizing divergences, performing variational inference, generative adversarial optimization, tocite a few prominent choices. Some of these methods may be more scalable and robust to optimization
errors. See Appendix D.1 for a discussion on how the theory generalizes for other architectures.
Further, we note that if V comes from continuous domains, there are many ways the architectureof the NCM could be augmented accordingly. As discussed in Footnote 10, one could replace theGumbel-max trick in the architecture in Eq. 2 with a model that directly computes a probability
density given a data point. Some of the alternative architectures mentioned above may work as well.
We believe this leads to an exciting research agenda that is to understand the tradeoffs involved in the
choice of the architectures and how to properly optimize NCMs for specific applications.

C

Examples and Further Discussion

In this section, we complement the discussion provided in the main paper through examples. Specifically, in Sec. C.1, we discuss what expressiveness means and provide examples to show why it’sinsufficient to perform cross-layer inferences. In Sec. C.2, we provide an intuitive discussion on
why causal diagrams are able to perform cross-layer inferences and basic examples illustrating thestructural constraints encoded in such models, which can be seen as an inductive bias as discussed
in the body of the paper. In Sec. C.3, we exemplify how this inductive bias can be added to NCMs
such that they are capable of solving ID instances. In Sec. C.4, we discuss possible reasons why one
would prefer to perform ID through neural computation instead the machinery of the do-calculus.
C.1

Expressiveness Examples

In this section, we try to clarify through examples the notion of expressiveness, as shown in Thm. 1,
and discuss the reasons it alone is not sufficient for performing cross-layer inferences.
Example 1. Consider a study on the effects of diet (D) on blood pressure (B), inspired by studies
such as [2]. D and B are binary variables such that D = 1 represents a high-vegetable diet, andB = 1 represents high blood pressure. Suppose the true relationship between B and D is modeledby the SCM M∗ = {U, V, F, P (U)}, whereU:= {UD , UDB , UB1 , UB2 }, all binary




V
:= {D, B}fD (UD , UDB )= ¬UD ∧ ¬UDB∗
M := F
:=

f
(D,
U
,
U
)
=
((¬D ⊕ UB1 ) ∨ UDB ) ⊕ UB2
B1
B2

 B



P (UD = 1) = P (UDB = 1) = P (UB1 = 1) = P (UB2 = 1) = 41
P (U) :=all U ∈ U are independent(24)
The set of exogenous variables U affects the set of endogenous variables V. For example, UDB is anunobserved confounding variable that affects both diet and blood pressure (ethnicity, for example),while the remaining variables in U represent other factors unaccounted for in the study. F describes
the relationship between the variables in V and U, and P (U) describes the distribution of U.
This SCM M∗ induces three collections of distributions corresponding to the layers of PCH withrespect to V. These can be summarized in Table 1. For example, a layer 1 quantity such as
30

UD UDB UB1 UB2 D B
P (U)
0
0
0
0
1
¬D p0 = 81/256
0
0
0
1
1
D
p1 = 27/256
0
0
1
0
1
D
p2 = 27/256
0
0
1
1
1
¬D p3 = 9/256
0
1
0
0
0
1
p4 = 27/256
0
1
0
1
0
0
p5 = 9/256
0
1
1
0
0
1
p6 = 9/256
0
1
1
1
0
0
p7 = 3/256
1
0
0
0
0
¬D p8 = 27/256
1
0
0
1
0
D
p9 = 9/256
1
0
1
0
0
D
p10 = 9/256
1
0
1
1
0
¬D p11 = 3/256
1
1
0
0
0
1
p12 = 9/256
1
1
0
1
0
0
p13 = 3/256
1
1
1
0
0
1
p14 = 3/256
1
1
1
1
0
0
p15 = 1/256
Table 1: Truth table showing induced values of M∗ for Example 1. Probabilites in P (U) are labeledfrom p0 to p15 for convenience.

P (B = 1 | D = 1), the probability of someone having high blood pressure given a high-vegetablediet, can be computed as
P (B = 1 | D = 1)==

P (D = 1, B = 1)
P (D = 1)
p1 + p2
54= 0.375.
=
p0 + p1 + p2 + p3
144

(25)
(26)

A layer 2 quantity such as P (B = 1 | do(D = 1)), the probability from M∗ of someone having highblood pressure when intervened on a high-vegetable diet, can be computed as
P (B = 1 | do(D = 1))= p1 + p2 + p4 + p6 + p9 + p10 + p12 + p14
120= 0.46875.
=
256

(27)
(28)

Layer 3 quantities can also be computed, for example, P (BD=1 = 1 | D = 0, B = 1). Given that anindividual has high blood pressure and a low-vegetable diet, this quantity represents the probability
that they would have high-blood pressure had they instead eaten a high-vegetable diet. This can becomputed as
P (BD=1 = 1 | D = 0, B = 1)
P (BD=1 = 1, D = 0, B = 1)
p4 + p6 + p12 + p14
48===≈ 0.6154.
P (D = 0, B = 1)
p4 + p6 + p8 + p11 + p12 + p14
78

(29)

Following the construction in the proof for Thm. 1, we will show the (somewhat tedious) constructionof the corresponding NCM that induces the same distributions. First, we build a simple canonical
SCM from Def. 10 to match the functionality in M∗ . We build MCM = ⟨UCM , V, FCM , P (UCM )such that
UCM := {RD , RB }, DRD = {0, 1}, DRB = {0, 1, 2, 3}





V
:= {D,

 B}


CM


fD
(RD )
= RD






MCM :=(30)
0
if RB = 0







F
:=
D
if
R
=
1
B
 CM


fBCM (D, RB ) =





¬D if RB = 2








1
if RB = 331

Looking at Table 1, we mimic the same distributions of M∗ in MCM by choosingp5 + p7 + p13 + p15 = 16/256 RD = 0, RB = 0RD = 0, RB = 1
p9 + p10 = 18/256



p
+
p
=
30/256RD = 0, RB = 211 8P (UCM ) = P (RD , RB ) = p4 + p6 + p12 + p14 = 48/256 RD = 0, RB = 3p1 + p2 = 54/256
RD = 1, RB = 1




p
+
p
=
90/256RD = 1, RB = 2

0
3


0
otherwise.

(31)

We state the following useful neural network functions defined in the proof of Thm. 1:
Pn• fˆAND (x1 , . . . , xn ) = σ ( i=1 xi − n)Pn
• fˆOR (x1 , . . . , xn ) = σ ( i=1 xi − 1)
• fˆNOT (x) = σ (−x)• fˆ≥z (x) = σ (x − z)
For this appendix, σ will be the binary step activation function. fˆAND , fˆOR , and fˆNOT compute thebitwise AND, OR, and NOT of the inputs (if binary) respectively. fˆ≥z will output 1 if its input isgreater than or equal to z and will output 0 otherwise.
b V, F,b as follows:c = ⟨U,b P (U)
We begin the construction of our NCM M
bb }, D b = [0, 1]
U
:= {U

U



:= {D,

V
( B}
c :=
b)
M
fˆ (U
= ?
Fb
:= ˆD

b

f
(D,
U
)
= ?
B



b
b ) ∼ Unif(0, 1)
P (U):= P (Ub With the goal of reproducing the behavior of MCM ,We must then construct the neural networks in F.
we first start by converting a uniform distribution into P (RD , RB ). We can accomplish this by dividing the [0, 1] interval into chunks for each individual value of (RD = rD , RB = rB ) with the sizeof P (RD = rD , RB = rB ). For instance, considering values of P (RD , RB ) in the order in Eq. 31,
the interval [0, 16/256) would correspond to (RD = 0, RB = 0), the interval [16/256, 34/256)
b would be broken into six
would correspond to (RD = 0, RB = 1), and so on. In this case, Uintervals corresponding to the 6 cases of Eq. 31: [0, 16/256), [16/256, 34/256), [34/256, 64/256),[64/256, 112/256), [112/256, 166/256), and [166/256, 1). For the sake of convenience, we willlabel these I1 to I6 respectively
We can check if U is contained within an interval like [16/256, 34/256) with the following neuralnetwork function:fˆI2 = fˆ[16/256,34/256) (u) = fˆAND fˆ≥16/256 (u), fˆNOT fˆ≥34/256 (u)(32)
b . Mapping this encoding toObserve that fI1 to fI6 provide a one-hot encoding of the location of U
RD and RB is simply multiplying the corresponding values of rD and rB as weights to the encoding:fˆRD (u) = 0 · fˆI1 (u) + 0 · fˆI2 (u) + 0 · fˆI3 (u) + 0 · fˆI4 (u) + 1 · fˆI5 (u) + 1 · fˆI6 (u)fˆR (u) = 0 · fˆI (u) + 1 · fˆI (u) + 2 · fˆI (u) + 3 · fˆI (u) + 1 · fˆI (u) + 2 · fˆI (u)
B

1

2

3

4

5

6

(33)
(34)

Note that fˆRD and fˆRB are indeed neural networks, and this final layer does not contain an activation
function.
Since D = RD in MCM , we can already constructfˆD (u) = fˆRD (u).
32

(35)

The function fˆB is somewhat more involved since it must take D as an input. Since RB is not abinary variable, we first convert it to binary form to simplify the mapping. We can accomplish this byusing the same strategy of obtaining the one-hot encoding of RB . For instance, to check if RB = 1,
we can build the neural network functionfˆ=1 (rB ) = fˆAND fˆ≥1 (rB ), fˆNOT fˆ≥2 (rB ) .
(36)
The encoding is formed with fˆ=0 , fˆ=1 , fˆ=2 , and fˆ=3 .
Using this, we can construct fˆB (u) following the desired properties in Eq. 30:






fˆB (d, u) = fˆOR fˆAND fˆ=1 (rB ), d , fˆAND fˆ=2 (rB ), fˆNOT (d) , fˆ=3 (rB )(37)

c is complete.
where rB = fˆRB (u). With fˆD and fˆB defined, our construction of M
b
U
D B
P (U)
[0, 16/256)00q0 = 16/256[16/256, 34/256)0D
q1 = 18/256[34/256, 64/256)
0¬D q2 = 30/256[64/256, 112/256)01q3 = 48/256[112/256, 166/256) 1D
q4 = 54/256[166/256, 1)
1¬D q5 = 90/256
c for Example 1. Probabilites in P (U) are labeled
Table 2: Truth table showing induced values of M
from q0 to q5 for convenience.

c, as represented in Table 2, matches theWe can now verify that the distributions induced by M∗
distributions induced by M . Consider the same three queries from Eqs. 25, 27, and 29:
P M (B = 1 | D = 1) =c

P M (D = 1, B = 1)cc
(D = 1)
PM

=

q4
54
= 0.375=
q4 + q5
144

P M (B = 1 | do(D = 1)) = q1 + q3 + q4 =c120
= 0.46875
256

P M (BD=1 = 1 | D = 0, B = 1)c

P M (BD=1 = 1, D = 0, B = 1)
c

=

c
PM
(D = 0, B = 1)

=

q3
48
=
≈ 0.6154
q2 + q3
78

This demonstrates that the NCM is indeed expressive enough to model this setting on all three layersof PCH. While a more basic model might be fitted to answer L1 queries (such as P (B = 1 | D = 1)),a well-parameterized NCM is expressive enough to represent distributions on higher layers.
■
Example 1 shows a scenario where the expressiveness of the NCM class allowed us to fit an NCM
instance that could completely match a complex SCM and answer any question of interest. However,
we also highlight that expressiveness alone does not necessarily mean that the NCM can solve any
causal problem. Experimental data, data from layer 2, can be difficult to obtain in practice, so it
c only on observational data from layer 1, then deducewould be convenient if we could fit a model M
c as if it were the true SCM, M∗ . Unfortunately, Corol. 1 states thatthe same causal results using M
this deduction typically cannot be made no matter the expressiveness of the model. The next example
will illustrate this point more concretely.
Example 2. Consider the same study of the effects of diet on blood pressure in Example 1 in which
the two variables are described by the SCM, M∗ , in Eq. 24.
c which matched M∗ ’s behavior on
While in the previous example we were able to construct NCM M
all three layers of the PCH, this was contingent on having access to the true SCM. This is unlikely to33

D B P (D, B)
0034/2560
1
78/2561
090/2561
1
54/256
Table 3: Observational distribution P (V) induced by M∗ from Example 1.

happen in practice. Instead, we typically only have partial information from the SCM. In many cases,
we may only have observational data from layer 1. The data in Table 3 exemplifies the aspect of M∗
we may have access to.
Naturally, we should construct an NCM such that matches on the given observed dataset. The NCM
c from Example 1 will indeed induce the same observational data P (V), but there are several otherMways we could construct a model that fits such criterion. For illustration purposes, consider fourb V, Fbi , P (U)⟩b is defined as follows:
c1 , Mc2 , Mc3 , and M
c4 such that M
ci = ⟨U,
NCMs MbbD , UbB }, D b = D b = [0, 1]

U
:= {U

UD
UB


V
:= {D, B}
i ˆi

Fbi
:= {fˆD, fB } bbbB ∼ Unif(0, 1), UbD ⊥bB
P (U) := UD , U⊥Ub with the intent of simplifying some of the expressions, but it is feasible to
We use two variables in U
construct NCMs with the same behavior using one uniform random variable, similar to Example 1.
c1 has no unobserved confounding,Concretely, we construct Fb1 such that M
1 ud ≥ 112

1
256
ˆ

f
(u
)
=
 D d

0 otherwise34
Fb1 :=
1 (d = 0) ∧ (ub ≥ 112 )
 ˆ1
90


f (d, ub ) = 1 (d = 1) ∧ (ub ≥ 144
)

 B


0 otherwise(38)

The corresponding neural network for Fb1 can be seen as
1fˆD(ud ) = fˆ≥112/256 (ud )





fˆB1 (d, ub ) = fˆOR fˆAND fˆNOT (d), fˆ≥34/112 (ub ) , fˆAND d, fˆ≥90/144 (ub ) .

c2 is reversed, i.e.,
Fb2 is constructed such that the causal direction of D and B in M34
1 (b = 0) ∧ (ud ≥ 124 )



78
2
ˆ

fD (b, ud ) = 1 (b = 1) ∧ (ud ≥ 132 )Fb2 :=
0 otherwise
1 ub ≥ 124

2
256

=
fˆB (ub )0 otherwise
The corresponding neural network for Fb2 can be written as





2
fˆD
(b, ud ) = fˆOR fˆAND fˆNOT (b), fˆ≥34/124 (ud ) , fˆAND b, fˆ≥78/132 (ud )fˆB2 (ub ) = fˆ≥124/256 (ub ).

(39)
(40)

(41)

(42)
(43)

34

c
Fb3 is constructed such that P M3 (B = 1 | do(D = 1)) is maximized, namely,
112
1 ud ≥ 256
ˆ3 (ud )

f
=
D


0 otherwise




34
) ∧ (ud < 112
1 (d = 1) ∧ (ub < 112

256 )

Fb3 :=
34112

1 (ub ≥ 112 ) ∧ (ud < 256 )
3fˆB (d, ub , ud ) = 1 (d = 1) ∧ (u < 54 ) ∧ (u ≥ 112 )

b
d


144
256



0 otherwise(44)

The corresponding neural network for Fb3 can be written as3fˆD(ud ) = fˆ≥112/256 (ud )







fˆAND d, fˆNOT fˆ≥34/112 (ub ) , fˆNOT fˆ≥112/256 (ud )






fˆB3 (d, ub , ud ) = fˆOR fˆAND fˆ≥34/112 (ub ), fˆNOT fˆ≥112/256 (ud )







fˆAND d, fˆNOT fˆ≥54/144 (ub ) , fˆ≥112/256 (ud ) .

Finally, Fb4 is constructed such that P M4 (B = 1 | do(D = 1)) is minimized,
1 ud ≥ 112

4
256
ˆ

=
fD (ud )
0 otherwise


34
112
Fb4 :=
1 (d = 0) ∧ (ub ≥ 112 ) ∧ (ud < 256 )

54

4
ˆ

fB (d, ub , ud ) = 1 (d = 1) ∧ (ub < 144 ) ∧ (ud ≥ 112

256 )



0 otherwise

(45)

(46)

c

(47)

The corresponding neural network for Fb4 can be written as
4fˆD(ud ) = fˆ≥112/256 (ud )fˆAND fˆNOT (d), fˆ≥34/112 (ub ), fˆNOT fˆ≥112/256 (ud )fˆB4 (d, ub , ud ) = fˆOR
fˆAND d, fˆNOT fˆ≥54/144 (ub ) , fˆ≥112/256 (ud ) .

(48)
(49)

Even though the functions of these NCMs are constructed in very different ways, one can verify thatthey indeed induce the same layer 1 as shown in Table 3.
Despite this match, they all disagree on a simple layer 2 quantity such as P (B = 1 | do(D = 1)); towitness note that54c
P M1 (B = 1 | do(D = 1)) = P (B = 1 | D = 1) == 0.375
(50)
144
132
c
P M2 (B = 1 | do(D = 1)) = P (B = 1) =≈ 0.5156
(51)
256
166
c
P M3 (B = 1 | do(D = 1)) =≈ 0.6484
(52)
256
54
c
P M4 (B = 1 | do(D = 1)) =≈ 0.2109(53)
256
Without further information, it’s not possible to distinguish which model (if any) is the correct one.
Naïevely, choosing an arbitrary model is likely to result in misleading results, even if the model can
reproduce the given L1 data with high fidelity.
In practice, depending on the chosen model, the conclusion of the study could be dramaticallyc1 or M
c4 may conclude that a high-vegetable dietdifferent. For instance, someone who fits models M
c2 may conclude that itis beneficial for lowering blood pressure, while someone who fits model Mchas no effect at all. Someone who fits model M3 may even conclude that eating more vegetables isharmful for regulating blood pressure.
■
35

C.2

Structural Constraints Embedded in Causal Bayesian Networks

In this section, we provide an example to illustrate the inductive bias embedded in causal diagrams,
building on the more comprehensive treatment provided in [5, Sec. 1.4].
Example 3. Consider the following two SCMs:
U:= {UX , UY }, all binary:= {X, Y }, all binary
V
 1
M1 :=
fX (UX )
= UX

F1
:=

1

f
(X,
U
)
=
X ⊕ UYYYP (U) := P (U = 1) = 1 , P (U = 1) = 1 , U ⊥Y
X ⊥ UYX
2
4
U:= {UX , UY }, all binary:= {X, Y }, all binary
V
 2
M2 :=
fX (Y, UX ) = Y ⊕ UX

F2
:=


fY2 (UY )= UYP (U) := P (U = 1) = 1 , P (U = 1) = 1 , U ⊥Y
X ⊥ UYX
4
2
Note that both M1 and M2 induce the same L1 distributions.
For example, in both models, P (Y = 1) = 12 , and P (Y = 1 | X = 1) = 34 . However, even without
making any computation, it seems intuitive from the structure of the functions and noise that a causal
query like P (Y = 1 | do(X = 1)) would have different answers in both models. First, note that fY2 in
M2 does not have X as an argument, and there are no other variables in V, so intervening on X would
have no causal effect on Y . In other words, the constraint P M2 (Y = 1 | do(X = 1)) = P (Y = 1) is
implied. More subtly in the case of M1 , we note that X directly affects Y and there is no unobserved
confounding between X and Y . This means that the observed association between X and Y must be
due to the causal effect (i.e. P M1 (Y = 1 | do(X = 1)) = P (Y = 1 | X = 1)). The relationshipbetween X and Y in these two cases can be seen graphically, as shown in Fig. 9.
XYX(a) Graph for M1 .

Y(b) Graph for M2 .

Figure 9: Causal diagrams for SCMs in Example 3. A directed edge from A to B indicates that A is
an argument of the function for B.
■
As illustrated in the previous example, and discussed more formally in [5], these equality constraints
across distributions arise from the qualitative structural properties of the SCM such as which variable
is an argument of which function, and which variables share exogenous influence. In fact, these
constraints are invariant to the details of the functions and the distribution of the exogenous variables.
Moreover, there are exponentially many constraints implied by an SCM in the collection of L1 andL2 distributions, which can be parsimoniously represented in the form of a causal bayesian network(Def. 15)12 In fact, the graphical component of this object provides an intuitive interpretation for these
constraints. It can be shown that the closure of such constraints entails the do-calculus [5, Thm. 5],
which means that all identifiable effects can be computed from them (due to the completeness shownin [46]).
Revisiting Examples 1 and 2 and applying the definition of causal diagram (Def. 12), we can see
from the structure of M∗ that the causal diagram G in Fig. 10 is induced. If we had this information,
c2 from Example 2 as a possible model. The reason is that we canwe could immediately eliminate M
read off from diagram G that B cannot be an argument of fD .
12This is a generalization of the notion of markov compatibility used in L1 models, such as bayesian networks[56]. In our case, there are multiple distributions of different nature, observational and experimental, and theconstraints are among them (i.e., not conditional independences).

36

D

B

Figure 10: Causal diagram G of M∗ from Example 1

With an SCM-like structure, the NCM naturally induces its own structural constraints. Def. 7 in themain paper shows how to construct an NCM to fit the same constraints entailed by a given causal
diagram from another SCM. In some way, the original model induces mark in the collection ofobservational and experimental distributions. In the case of the NCM, these constraints are used as
input, inductive bias to constrain its functions. This is powerful because any inferences performed on
a G-constrained NCM will automatically satisfy the constraints of G.
C.3

Solving Identification through NCMs(a) In the identifiable case, all NCMs thatare G-consistent and L1 -consistent with M∗
will also match in Q.

(b) In the non-identifiable case, there could
c1 and M
c2 , that are both
exist two NCMs, M
G-consistent and L1 -consistent but still disagree in Q.

b i is the
Figure 11: A visual representation of the ID problem. Here, Q is a query of interest, and Qcanswer for that query induced by NCM Mi . The goal is to check if all NCMs that are G-consistentand L1 -consistent are also consistent in Q.
The notion of identification requires that a certain effect is identifiable by all (unobserved) SCMs
compatible with the corresponding structural constraints. This was extended to NCMs through Def.
8; see also Fig. 11. In fact, Alg. 1 helps to solve the neural identification problem such that if there
are two NCMs compatible with the constraints but with different predictions for the causal effect, it
will return “FAIL”. Otherwise, it will returns the estimation of the query in every ID case. Note that
identification of an effect does not require that the NCM and the true SCM have the same functions,just the effects need to match. The following two examples illustrate both positive and negative
instances of such operation.
Example 4. Consider once again the study of diet on blood pressure introduced in Example 1.
Suppose we are particularly interested in the L2 expression of Q = P (B = 1 | do(D = 1)), thecausal effect of diet on blood pressure. The true SCM M∗ is not available, but L1 data (P (v))
presented in Table 3 is (as shown Example 2). Furthermore, we are informed by a doctor that thetwo variables follow the relation specified by the causal diagram G in Fig. 10. Is Q identifiable from
P (v) and Ω(G), where Ω(G) is the set of all G-constrained NCMs?
Unfortunately, the answer is no for this particular case. To see why, example 2 provides 4 NCMs
c2 can be eliminated as awhose L1 distributions match P (v) but disagree on Q. Even though M
possible proxy since it is not G-consistent, the other three models are compatible with G, so we stillcannot pinpoint the correct answer for Q.
37

∗Running Alg. 1 on this setting would result in the algorithm generating two sets of parameters, θmin∗and θmax , that minimize and maximize Q. The behaviors of an NCM with these parameters may
c3 and M
c4 from Example 2, and they do not agree on Q.
reflect the behaviors of M■

Example 5. Suppose now we return to the data collection process and we receive new information
about a third variable, sodium intake (S) (S = 1 represents a high sodium diet, 0 otherwise).
With the introduction of S in the endogenous set V, M∗ can be written as follows:U:= {UD , UDB , US , UB }, all binary





V
:= {D, S, B}






fD (UD , UDB ) = ¬UD ∧ ¬UDB
M∗ := F:= fS (D, US )= ¬D ⊕ US




f
(S,
U
)
=
(S ∨ UDB ) ⊕ UB
B


 B


P (UD = 1) = P (UDB = 1) = P (US = 1) = P (UB = 1) = 14
P (U) :=all U ∈ U are independent(54)

As reflected in the updated M∗ , diet only affects blood pressure through sodium content, which tends
to be higher in low-vegetable diets. Note that the L1 , L2 , and L3 distributions relating D and B are
unchanged with this modification of M∗ . In this case, the query of interest is evaluated as
P (B = 1 | do(D = 1)) = P ((SD=1 ∨ UDB ) ⊕ UB = 1)
= P (((¬1 ⊕ US ) ∨ UDB ) ⊕ UB = 1)
= P ((US ∨ UDB ) ⊕ UB = 1)120
= 0.46875,
=
256

(55)

which matches the result in Eq. 27.
D S B P (D, S, B)
0
0 0
13/2560
0 1
15/2560
1 0
21/2560
1 1
63/256
1
0 0
81/2561
0 1
27/256
1
1 0
9/256
1
1 1
27/256
Table 4: Updated observational distribution P (V) induced by M∗ for Example 5.

D

S

B

Figure 12: Causal diagram G of M∗ with additional S variable for Example 5This is just the computation of the distribution from Nature’s perspective. As the previous examples,
we do not have access to the true model (M∗ ), just the observational distribution P (v), as shown in
Table 4. We do have access to the updated causal diagram as shown in Fig. 12.
The addition of the new variable and the refinement of the model change the identifiability status of∗
the query Q = P (B = 1 | do(D = 1)). No matter how Alg. 1 chooses the parameters for θminand∗c
θmax , M will always induce the same result for Q as long as it induces the correct P (v). Specifically,38

through standard do-calculus derivation we would obtain:
P (B = 1 | do(D = 1))
X
P (s | do(D = 1))P (B = 1 | do(D = 1), s)=

Marginalization

s∈DS

=

X

P (s | do(D = 1))P (B = 1 | do(D = 1), do(s))

Rule 2P (s | do(D = 1))P (B = 1 | do(s))

Rule 3P (s | D = 1)P (B = 1 | do(s))

Rule 2

s∈DS

=

X
s∈DS

=

X
s∈DS

=

X

P (s | D = 1)

s∈DS

=

X
X
s∈DS

P (B = 1 | d, do(s))P (d | do(s))

Marginalizationd∈DD

P (s | D = 1)

s∈DS

=

X
X

P (B = 1 | d, do(s))P (d)Rule 3

P (B = 1 | d, s)P (d)Rule 2d∈DD

P (s | D = 1)X
d∈DD

Finally, we can replace the corresponding probabilities with the actual values, i.e.,
P (B = 1 | do(D = 1)) = P (S = 0 | D = 1)P (B = 1 | D = 0, S = 0)P (D = 0)
+ P (S = 0 | D = 1)P (B = 1 | D = 1, S = 0)P (D = 1)
+ P (S = 1 | D = 1)P (B = 1 | D = 0, S = 1)P (D = 0)
+ P (S = 1 | D = 1)P (B = 1 | D = 1, S = 1)P (D = 1)

 
 



108
15
112
108
27
144
=
+
144
28
256
144
108
256

 
 
 

36
63
112
36
27
144
+
+
144
84
256
144
36
256
15
= 0.46875
=
32

(56)

On the other hand, any G-constrained NCM that induces P (v) will produce the same result, matching
Eq. 56. For instance, consider the following NCM construction:


b
U





V















bDB , UbS }, D b = D b = [0, 1]
:= {U
UDB
US
:= {D, S, B}
1 uDB ≥ 112

256
ˆ

f
(u
)
=

D DB

0 otherwise




1


1 (d = 0) ∧ (uS ≥ 4 )



c :=
M
fˆS (d, uS )= 1 (d = 1) ∧ (uS ≥ 34 )


Fb
:=



0 otherwise








52
112
220



1 (s = 0) ∧ ( 256 ≤ uDB < 256 ) ∨ (uDB ≥ 256 )





28
112
148



≤ uDB < 256) ∨ (uDB ≥ 256)
fˆB (b, uDB ) = 1 (s = 1) ∧ ( 256







0 otherwise bbDB , UbS ∼ Unif(0, 1), UbDB ⊥bS
P (U) := U⊥U
(57)
The corresponding neural network for Fb can be written as39

fˆD (uDB ) = fˆ≥112/256 (uDB )





fˆS (d, uS ) = fˆOR fˆAND fˆNOT (d), fˆ≥1/4 (uS ) , fˆAND d, fˆ≥3/4 (uS )ˆAND fˆNOT (s), fˆ≥52/256 (uDB ), fˆNOT fˆ≥112/256 (uDB )

f







fˆAND fˆNOT (s), fˆ≥220/256 (uDB )fˆB (s, uDB ) = fˆOR
ˆAND s, fˆ≥28/256 (uDB ), fˆNOT fˆ≥112/256 (uDB )

f







fˆAND s, fˆ≥148/256 (uDB ) .

(58)
(59)

(60)

c follows the format of a G-constrained NCM defined in Def. 7. Additionally, one canNote that M
c induces the same L1 quantities shown in Table 4. Applying the mutilation procedure
verify that M
c to compute the query,on M
P M (B = 1 | do(D = 1))

 

52
112
220
= P (SD=1 = 0)P≤ UDB <∨ UDB ≥
256
256
256
 


112
148
28
≤ UDB <∨ UDB ≥+ P (SD=1 = 1)P
256
256
256




96
192
=
P (SD=1 = 0) +P (SD=1 = 1)
256
256
 
 
 


3
192
3
96
P US <+P US ≥
=
256
4
256
4
72
48
120
=
+
=
= 0.46875.
256 256256c is constructed to fit P (v) and not necessarily
This result indeed matches Eq. 55. We further note M∗
to match M . This is evident when comparing the inputs and outputs of the functions in Fb to thosec alsofrom M∗ . Still, due to the structural constraints encoded in the NCM, it so happens that M
matches in our L2 query of interest even though it is only constructed to match only on layer 1. It
is remarkable that incorporating these family of constraints into the NCM structure allows one tosuccessfully perform cross-layer inferences.
c■Thm. 4 is powerful because it says that performing the identification task in the class of NCMs will
yield the correct result, even if the true model can be any SCM. We note that this is not the case forevery class of models, even if a model from that class can be both L1 -consistent and G-consistent
with the true model. In particular, the expressivity of the NCM allows for this result, and using a lessexpressive model may produce incorrect results. We illustrate this with the following examples.
Example 6. Suppose we attempt to identify P (B = 1 | do(D = 1)) from the problem in Example 4
using a less expressive model class such as the set of all Markovian models. Recall that the given
observational P (V) is shown in Table 3, and the given causal diagram G is shown in Fig. 10. An
example model from the class of Markovian models that achieve L1 and G consistency with M∗ is
c1 from Example 2.
M
Note that due to the lack of unobserved confounding in Markovian models, the induced value
c1 isfor P (B = 1 | do(D = 1)) for any L1 and G-consistent Markovian model including M
54
P (B = 1 | do(D = 1)) = P (B = 1 | D = 1) = 144 = 0.375. Since all models from thisclass (Markovian) agree on the same value for this quantity, the conclusion reached is that it must∗be identifiable. However, this is clearly not the case, as we know the true value, P M (B = 1 |do(D = 1)) = 0.46875. In this case, the reason we reach the wrong result is that the true model
is not Markovian, and the set of all Markovian models is not expressive enough to account for all
possible SCMs.
■
More interestingly, another example using a different class of models follows.
40

Example 7. Consider a special class of SCMs which, given variables V and the graph G, take thefollowing structure.

c=
M


b

U


b

V







Fb














b
bC : C ∈ C 2 (G)}, D b = [0, 1] for all Ub ∈ U,
:= {U
U
:= V,
(
! 
)

L
L
:= fˆV (paV , uV ) =x ⊕1(aV,i ≤ ui < bV,i ) : V ∈ V ,ui ∈uVx∈paVaV,i , bV,i ∈ [0, 1], aV,i ≤ bV,i ,paV is the set of parents of V in G,
bC : C ∈ C 2 (G) such that V ∈ C},
uV = {Ubbbb ∈ U.
P (U) := U ∼ Unif(0, 1) for all U(61)
Here, C 2 (G) denotes the set of all C 2 -components of G. The ⊕ operator denotes bitwise XOR, withthe larger version representing the bitwise XOR of all elements of a set (0 if empty).

X

X
0
0
1
1

Y

Y
0
1
0
1

P (X, Y )
p0
p1
p2
p3

Table 5: General observational distribution P (V)Figure 13: Causal diagram G of M∗ from Exam- induced by M∗ from Example 7. We assume
ple 7
positivity (i.e. pi > 0 for all i).
We may opt to use a model like this for its simplicity, since having fewer parameters allows for easier
optimization. Suppose we try to use this model class to decide if P (Y | do(X)) is identifiable in thecase where the true model, M∗ , induces the graph G in Fig. 13. We are given G along with P (v),c from Eq. 61, it would have
which can be represented as shown in Table 5. If we construct a model M
the following form.

c=
M


b

U




b

V

Fb





P (U)
bbXY }, D b:= {UUXY = [0, 1],:= ({X, Y }fˆ (bu )
= 1(aX ≤ ubXY < bX ),:= ˆX XYfY (x, ubXY ) = x ⊕ 1(aY ≤ ubXY < bY ):= UXY ∼ Unif(0, 1).

The parameters we choose to fit P (V) are the values of aX , bX , aY , bY . However, note that there inc to attain L1 -consistency with M∗ , we must have:order for M
1. bX − aX = p2 + p3 .
2. (aX − aY = p1 and bY − aX = p2 ) or (bY − bX = p1 and bX − aY = p2 )2 implies bY − aY = p1 + p2 , so in all cases, P M (Y = 1 | do(X = 0)) = p1 + p2 andcc
P M (Y = 1 | do(X = 1)) = p0 + p3 . In other words, since P M (Y | do(X)) matches for all models
from this class that are L1 and G-consistent, the conclusion reached is that it must be identifiable.
c41

However, suppose M∗ takes the following form:U:= {UX , UY }, DUX = DUY = {0, 1},




V
:= {X, Y }






fX (uX )= uX ,
F:=f (x, uY ) = uY ,
Y
M∗ =

P (UX = 0, UY = 0) = p0







P (UX = 0, UY = 1) = p1

P (U) :=
P (UX = 1, UY = 0) = p2





P (UX = 1, UY = 1) = p3
One can quickly verify that M∗ does indeed induce the P (V) in Table 5 and G from Fig. 13. Notethat in this M∗ , P (Y = 1 | do(X = 0)) = P (Y = 1 | do(X = 1)) = p1 + p3 . In fact, thisc. Like shown in Example 4,means there is a complete mismatch from any possible choice of M
P (Y | do(X)) is actually a non-identifiable query when G takes the form in Fig. 13. Simply put,M∗ could be an SCM for which the model class in Eq. 61 is not expressive enough to capture.
■

42

C.4

Symbolic versus Optimization-based Approaches for Identification

In this section, we discuss the relationship between current approaches to causal identification/estimation versus the new, neural/optimization-based approach proposed in this work.
The problem of effect identification has been extensively studied in the literature, and [57] introduced
the do-calculus (akin to differential or integral calculus), a set of symbolic rules that can be applied
to any expression and evaluate whether a certain invariance across interventional distributions holdgiven local assumptions encoded in a causal diagram. Multiple applications of the rules can be
combined to search for a reduction from a target effect to the distributions in which data is available.
There exist algorithms capable of utilizing the structural constraints encoded in the causal diagram,based on what is known as c-component factorization [67], to find a symbolic expression of the L2query in terms of the L1 distribution efficiently (for more general tasks, see, e.g., [46, 13]). We callthis approach symbolic since it aims to find a closed-form expression of the target effect in terms of
the input distributions.
Alternatively, one could take an optimization-based route to tackle the identification problem, such as
in Alg. 1 discussed in Sec. 3. This approach entails a search through the space of possible structuralmodels while trying to maximize/minimize the value of the target query subject to the constraints
found in the inputted data. We call this an optimization-based approach. These two approaches areindeed linked as evident from Thm. 2, which establishes a duality saying that the identification statusof a target query is shared across symbolic and optimization-based approaches.
We discuss next some of the possible trade-offs and synergies between these two families of methods.
We start with the symbolic approach and re-stating the definition of identification [58], with minor
modifications to highlight its model-theoretic perspective regarding the space of SCMs:
Definition 17 (Causal Effect Identification). Let Ω∗ be the space containing all SCMs definedover endogenous variables V. We say that a causal effect P (y | do(x)) is identifiable from theobservational distribution P (v) and the causal diagram G if P M1 (y | do(x)) = P M2 (y | do(x)) for
every pair of models M1 , M2 ∈ Ω∗ such that M1 and M2 both induce G and P M1 (v) = P M2 (v)■Fig. 14 provides an illustration of the many parts involved in this definition. In words, an interventionalΩ∗Structural Constraints
distribution Q = P (Y | do(x)) is said to be iden2
M
tifiable if for all SCMs in Ω∗ (top-left) that shareG
M1
the same causal diagram G (top-right), and induce
the same probability distribution P (V) (bottom-left),
Causal Diagram
they generate the same distribution to the target query
Q (bottom-right). In fact, identifiability can be underP M (Y|do(x)) =stood as if the details of the specific form of the true
P M (V)=P M (V)P M (Y|do(x))∗
SCM M – its functions and probability distribution
Interventional
Observational?
over the exogenous variables – are irrelevant, and the(L1 ) Distributions(L2 ) Distributions
Query
Data
constraints encoded in the causal diagram are sufficient to perform the intended cross-layer inference
Figure 14: P (Y | do(x)) is identifiable fromfrom the source to the target distributions.
P (V) and G if for all SCM M1 , M2 (topOne important observation that follows is that, oper- left) such that M1 , M2 match in P (V) (botationally, symbolic methods do not work directly in tom left) and G (top right), then they also
the Ω∗ space, but on top of the constraints implied match in the target distribution P (Y | do(x))
by the true SCM on the causal diagram. There are (bottom right).
a number of reasons for this, but we note that if allthat is available about M∗ are the constraints encoded in G, it is somewhat expected and reasonable
to operate directly on those, instead of considering the elusive, underlying structural causal model.
Further, we already know through the CHT that we will never be able to recover M∗ anyways, so
one could see it as unreasonable to consider M∗ as the target of the analysis. Still, even if we wanted
to refer directly to M∗ , practically speaking, searching through the space Ω∗ is a daunting task sinceeach candidate SCM M = ⟨F, P (U)⟩ ∈ Ω∗ is a complex, infinite dimensional object. Note thatthe very definition of identification (Def. 17) does not even mention the true SCM M∗ , since it iscompletely out of reach in most practical situations. The task here is indeed about whether one canget by without having to know much about the underlying collection of mechanisms and still answer
1

1

2

2

43

Unobserved
Reality

Causal Identification

Causal Estimation

Space ofObs. Distributions
P ∗ (V)

M∗

Space of All
SCMs (Ω∗ )Dataset D∗ (V)

Sampling

Task 1

Task 2

Query P ∗ (Y | do(X))
ID from ⟨G ∗ , P ∗ (V)⟩?

Fit Estimand fusing Data D∗ (V)No

Empirical
DistributionP ∗ (Y | do(X)) = f (P ∗ (V))

Yes

G∗

Causal Estimand

Space of
Causal Diagrams

Figure 15: Causal Pipeline with unobserved SCM M∗ in the left, generating both G and P (v), which
is taken as input for the identification task (1), which generates input to the estimation task (2).
the query of interest. (In causal terminology, an identification instance is called non-parametricwhenever no constraints are imposed over the functional class F or exogenous distribution P (U).
The full causal pipeline encompassing both tasks of effect identification and estimation is illustrated
in Fig. 15. Note that the detachment with respect to the true Nature, alluded to above, is quite
prominent in the figure. The very left part contains M∗ , which is abstracted away in the form of thecausal diagram G and through its marks imprinted into the observational distribution P (V). The
symbolic methods takes the pair ⟨G, P (V)⟩ as input (instead of the unobservable ⟨F ∗ , P ∗ (U)⟩), andattempt to determine whether the target distribution Q can be expressed in terms of the available
input distributions. Formally, the question asked is about whether there exists a mapping f such thatQ = fG (P (V)).

(62)

The decision problem regarding the existence of f (.) is certainly within the domain of causal
reasoning since it takes an arbitrary causal diagram as input, which encodes causal assumptions
about the underlying SCM, and reason through causal axioms on whether this is sufficient to performthe intended cross-layer inference. Causal reasoning is nothing more than the manipulation andsubsequent derivation of new causal facts from known causal invariances. Whenever this step is
successfully realized, one can then ignore the causal invariances (or assumptions) entirely, and simply
try to evaluate the r.h.s. of Eq. 62 to compute Q.
Space of All SCMs (Ω∗ )We note that in most practical settings, only a datasetwith samples collected from P (V) is available, say
M∗ = ⟨F ∗ , P ∗ (U)⟩
D(V), as opposed to the distribution itself. This
(unobserved truth)
entails the second task that asks for a computationallyM = ⟨F , P (U)⟩and statistically attractive way of evaluating the r.h.s.
of Eq. 62 from the finite samples contained in the
M′ = ⟨F ′ , P ′ (U)⟩dataset D(V). Even though the l.h.s. of Eq. 62
is a causal distribution, the evaluation is complete
Space of SCMs thatinduce G ∗ and P ∗ (V)oblivious to the semantics of such quantity and is(Ω∗ (G ∗ , P ∗ (V)))
entirely about fitting f using the data D(V) in thebest possible way.
Figure 16: In the case where Q is identifiable,
We now turn our attention to the optimization-based any two SCMs in Ω∗ (G ∗ , P ∗ (V)) – the spaceapproach as outlined in Alg. 1 (Sec. 3) and note that of SCMs matching M∗ in P ∗ (V) and G ∗ –it will have a very different interpretation of the iden- will also match M∗ in Q.
tifiability definition. In fact, instead of avoiding the
SCM altogether and focusing on the causal diagrams’ constraints, as done by the symbolic approach,it will put the SCM at the front and center of the analysis. Fig. 16 illustrates this point by showing
the space of all SCMs called Ω∗ (in dark gray). The true, unknown SCM M∗ is shown as a black44

dot and generates the pair ⟨G ∗ , P ∗ (V), the latter is taken as the input of the identification analysis.
The approach will then focus on the set of SCMs that have the same interventional constraints as G ∗(Def. 5) and that also have the capability of generating the same observational distribution P ∗ (V)(Def. 4). This subspace is called Ω∗ (G ∗ , P ∗ (V)) and marked in light gray. Since M∗ is almost neverinferrable, the optimization-approach will search for two SCMs M, M′ ∈ Ω∗ (G ∗ , P ∗ (V)) such thatthe former will try to maximize the target query (Qmax ), while the latter minimizes it (Qmin ). Twocandidate SCMs for this job are shown in the figure. Whenever the search ends and two of such SCMs
are discovered, they will predict exactly the same interventional distribution (i.e., Qmin = Qmax ) if
Q is identifiable. This is because by the definition of identifiability (Def. 17), all SCMs in the lightgray area will necessarily exhibited the same interventional behavior.
On the other hand, the situation is qualitatively
Space of All SCMs (Ω∗ )different when considering non-identifiable effects.
To understand how, the first observation comesfrom the contrapositive of Def. 17, which saysM∗ = ⟨F ∗ , P ∗ (U)⟩that non-identifiability implies there exists (at least)(unobserved truth)
two SCMs M, M′ within the Ω∗ (G ∗ , P ∗ (V))
M = ⟨F , P (U)⟩subspace that share the constraints as in G ∗′ = ⟨F ′ , P ′ (U)⟩M
and generate the same observational distribution(P (V) = P ′ (V)), but induce different interventional
Space of SCMs that
distributions(P (Y |do(X)) ̸= P ′ (Y |do(X))). The
induce G ∗ and P ∗ (V)optimization-based approach will try to exploit pre(Ω∗ (G ∗ , P ∗ (V)))
cisely this fact, searching for non-identifiability witnesses, possibly different than the true M∗ . Those Figure 17: In the case where Q is
are illustrated as red dots and hollow circles in Fig. 17. non-identifiable, there exist two SCMs in
Still, this is all that is needed to determine whether an Ω∗ (G ∗ , P ∗ (V)) (the space of SCMs matcheffect is not identifiable. In practice, each distribution ing M∗ in P ∗ (V) and G ∗ ) that do not match
Q, Q′ will only be approximations and it may be hard M∗ in Q.
to detect non-identifiability depending on how close
they are from each other. This is indeed what leads
to the probabilistic nature of such identifiability statements when using optimization-based methods(as discussed in Appendix B), as opposed to the deterministic ones entailed by the do-calculus andsymbolic family.
By and large, both approaches take the causal assumptions and try to infer something about theunknown, target quantity P ∗ (Y |do(X = x)) that is defined by the unobserved M∗ . In the case of
the symbolic approach, the structural assumptions encoded in the causal diagram G are used, while
an optimization-based approach will use constraints encoded through the scope of the functions andindependence among the exogenous variables U. Evaluating P ∗ (Y | do(X = x)) is possible inidentifiable cases, which means that our predictions will match what the true M∗ would say, while
the assumptions would be too weak in others cases, and non-identifiability will take place, whichmeans we are unable to make any statement about M∗ without strengthening the assumptions.
After having understood the different takes of both approaches to the problem of identification, we
consider again the entire pipeline shown in Fig. 15. We note that the two tasks, identification andestimation, are both necessary in any causal analysis, but they are usually studied separately in thesymbolic literature. Symbolic methods returns the identifiability status of a query and include themapping f whenever the effect is identifiable. The target quantity can then be evaluated by standard
statistical methods (plug-in) or more refined learning procedures, e.g., multi-propensity score/inverse
probability weighting [32], empirical risk minimization [33], and double machine learning [34].
On the other hand, the optimization-based framework proposed here is capable of identifying andestimating the target quantities in an integrated manner. As shown through simulations (Sec. 5), given
the sampling nature of the optimization procedure, the performance of the method relies not only
on the causal assumptions, but also on accurate optimization, which may require a large amount ofsamples and computation for training.
In practice, one may consider a hybrid approach where a symbolic algorithm for the identification
step is ran first, since it is deterministic and always returns the right answer, and then the estimation
step is performed through an NCM. With this use case in mind, we define Alg. 4 in Fig. 18 (left)
as this hybrid alternative to the more pure Alg. 1. In some sense, this approach combines the best45

Algorithm 4: Identifying queries with a symbolic ID
procedure and then estimating with NCMs.
Input : causal query Q = P (y | do(x)), L1 data
P (v), and causal diagram G∗
Output : P M (y | do(x)) if identifiable, FAIL
otherwise(a) Neural ID + Neural Estimation (Alg. 1)
if symbolicID(Q) thenc2
M ← NCM(V, G)// from Def. 7c3
θ ∗ ← arg minθ D(P M (θ) (v), P (v))// forsome divergence Dc ∗4
return P M (θ ) (y | do(x))
5 else6
return FAIL(b) Symbolic ID + Neural Estimation (Alg. 4)
1

Figure 18: (Left panel) Algorithm for solving identification problem with symbolic solvers andestimation with NCMs. (Right) Schematic illustrating differences between Alg. 1 (a) and Alg. 4 (b).
of both worlds – it relies on an ideal ID algorithm, which is correct with probability one, and thepowerful computational properties of neural networks, which may perform well and scale to complex
settings, for estimation. We illustrate this using the two figures in Fig. 18 (right).
After all, the NCM approach provides a cohesive framework that unifies both the causal and thestatistical components involved in evaluating interventional distributions. In the case of the hybrid
approach, we note that the causal reasoning is shifted to the symbolic identification methods. It
is remarkable but somewhat unsurprising that neural methods, which are the state-of-the-art forfunction approximations, are capable of performing the statistical step required for causal estimation.
More interestingly, we demonstrate in this work that neural nets (and proxy SCMs, in general) arealso capable of performing causal reasoning, such as in the inferences required to solve the ID
problem. Many other works have studied using neural networks as an estimation tool, as listed in the
introduction, but to the best of our knowledge, our work is the first one that utilizes neural networks
to provide a complete solution within the neural framework to the identification problem, and causal
reasoning more broadly.
In addition to showing that neural nets are also capable of performing causal reasoning, there are other
implications for using a proxy SCM in place of the true SCM, as opposed to abstracting the true SCM
entirely. Firstly, the generative capabilities of proxy SCMs, like the NCM, can be useful if the user
desires a source of infinite data, which is a quite common use case found in the literature. Secondly,
it provides quick estimation results for multiple queries via the mutilation procedure without theneed for retraining. Whenever we apply a symbolic approach we need to derive (and then train) a
specialized estimand, which can be time consuming. Thirdly, working in the space of SCMs tends toprovide straightforward interpretation of the causal problems using its semantics, which implies thatit has the potential to be more easily extensible to other related problems. One may be interested ingeneralizations of the ID problem such as identifying other types of queries or identifying and fusingfrom different sources and experimental conditions [4, 6, 46], such as in reinforcement learning. In
general, extending the line of reasoning of Alg. 1 to other identification cases is much simpler thanderiving a new symbolic solution under different constraints.

46

D

Generalizations

D.1

NCMs with other Functions and Noise Distributions (Proofs)

For the sake of concreteness and simplicity of exposition, the NCM from Def. 3 specifically uses
Unif(0, 1) noise for the variables in U and MLPs as functions. This leads to easy implementationand concrete examples for discussion (as in Appendix C).
We note that these are not meant to be limitations for the NCM framework. The NCM object canbe extended to use other function or noise types, provided they exhibit certain properties. We will
henceforth refer to specific versions of the NCM with their particular implementation of the noise
and functions (e.g., Def. 3 will be called NCM-FF-Unif).
Consider a more general version of the NCM below:c(θ) over variables
Definition 18 (NCM (General Case)). A Neural Causal Model (for short, NCM) M
b V, F,b such thatb Pb(U)⟩
V with parameters θ = {θVi : Vi ∈ V} is an SCM ⟨U,b ⊆ {UbC : C ⊆ V}, where each U
b is associated with some subset of variables C ⊆ V;
• U
• Fb = {fˆVi : Vi ∈ V}, where each fˆVi , parameterized by θVi ∈ θ, maps values of UVi ∪PaVi
b Vi ∈ C};
bC : UbC ∈ U,to values of Vi for some PaVi ⊆ V and UVi = {Uc(θ) should have the following properties:
Furthermore, a NCM Mbbbb ) (i.e. its cumulative(P1) For all U ∈ U, U has a well-defined probability density function P (Udensity function is absolutely continuous).
(P2) For all functions fˆVi ∈ Fb and all functions g : R → S, where S ⊂ R is a countable set, there
exists parameterization θV∗ i such that fˆVi (·; θV∗ i ) = g (universal representation).
■
We can use these properties to prove a more general version of Thm. 1. We first state the following
result to aid the proof.
Fact 5 (Probability Integral Transform [11, Thm. 2.1.10]). For any random variable X with awell-defined probability density function P (X), there exists a function f : DX → [0, 1] such thatf (X) is a Unif(0, 1) random variable.
■
The generalized proof follows.
Theorem 5 (NCM Expressiveness). For any SCM M∗ = ⟨U, V, F, P (U)⟩, there exists a NCM
b V, F,b s.t. Mc(θ) = ⟨U,b Pb(U)⟩c is L3 -consistent w.r.t. M∗ .
M■
Proof. Lemma 2 guarantees that there exists a canonical SCM MCM = ⟨UCM , V, FCM , P (UCM )⟩c, it suffices to show how to construct MCM
that is L3 -consistent with M∗ . Hence, to construct M
using the architecture of a NCM.
b = {UbV }. By property P1 and Fact 5, there exists a function g U
Following Def. 18, we choose U
U bsuch that g (UV ) is a Unif(0, 1) random variable.
Using the construction in Lem. 5, there must also exist a function g R such that
P (g R (g U (UcV ))) = P (UCM )(63)

b consider each fˆV ∈ F.
b Combining the above results, there must exist
To choose the functions of F,
i



R
U b
gVi = fVCM
pa
,
g
g
(
U
)
(64)
V
Vi
i
By property P2, we can choose parameterization θV∗ i such that fˆVi (·; θV∗ i ) = gVi .
c is constructed to match MCM on all outputs. Hence, for any
By Eqs. 63 and 64, the NCM M
counterfactual query φ, we havec |= φMCM |= φ ⇔ M
47and thereforec |= φ.
M∗ |= φ ⇔ M

The general G-constrained version of the NCM follows the same procedure as Def. 7.
Definition 19 (G-Constrained NCM (General Case)). Let G be the causal diagram induced by SCM
b if and only if C is a C 2 -component
b s.t. U
c as follows. (1) Choose U
bC ∈ UM∗ . Construct NCM M
b but it is sharedbbin G. Each UC has its own distribution P (UC ) independent of other variables in U,
as input to the functions of all variables in C. (2) For each variable Vi ∈ V, choose PaVi ⊆ V s.t.
for every Vj ∈ V, Vj ∈ PaVi if and only if there is a directed edge from Vj to Vi in G. Any NCM inthis family is said to be G-constrained. ■We prove a general version of Thm. 3 similarly.
Theorem 6 (NCM L2 -G Representation). For any SCM M∗ that induces causal diagram G, thereb V, F,b that is L2 -consistent w.r.t. M∗ .
c(θ) = ⟨U,b Pb(U)⟩
exists a G-constrained NCM M■
Proof. Fact ?? states that there exists a G-canonical SCM MGCM = ⟨UGCM , V, FGCM , P (UGCM )⟩c, we can simply show how to construct MGCM
that is L2 -consistent with M∗ . Hence, to construct M
using the architecture of a NCM.
b = {UbC : C ∈ C(G)}, where C(G) is the set of all C 2 -components
Following Def. 19, we choose Ubbof G. Denote UV = {UC : C ∈ C(G) s.t. V ∈ C}.
b V ) is a Unif(0, 1) random
By property P1 and Fact 5, there exists a function gVU such that gVU (Uvariable for each V ∈ V.
Using the construction in Lem. 5, there must also exist a function gVR such thatb V ))) = P (RV )P (gVR (gVU (U(65)

for each V ∈ V.
b Combining the above results, there must exist
b consider each fˆV ∈ F.
To choose the functions of F,
i



bV )
gVi = fVGCM
paVi , gVRi gVUi (U(66)
i
By property P2, we can choose parameterization θV∗ i such that fˆVi (·; θV∗ i ) = gVi .
c is constructed to match MCM on all outputs. Hence, M
c must be
By Eqs. 65 and 66, the NCM M
L2 -consistent with M∗ .
The remaining results, including Corol. 1, Thm. 2, Thm. 4, Corol. 2, Corol. 3, and Corol. 4 can beproven for NCMs with minimal changes to the proofs for NCMs.
D.2

Pearl’s Causal Hierarchy and Other Classes of Models

As developed in the paper, we note that the expressiveness power of NCMs is one desirable featuresof this class as models, which makes them comparable to the SCM class when considering the PCH’s
capabilities. Broadly speaking, neural networks are well understood to be maximally expressive
due to the Universal Approximation Theorem [14]. We note that Theorem 1 follows the same spirit
when considering causal inferences, i.e., NCMs is a data structure built from neural networks that are
maximally expressive on every distribution in every layer of the PCH generated by the underlying
SCM M∗ , and which has the potential of acting as a proxy under some conditions. This capability
is not shared across all neural architectures, and to understand how this discussion extends to theseother classes, we define expressivity more generally (Fig. 19):
Definition 20 (Li -Expressiveness). Let Ω∗ be the set of SCMs and Ω be a model class of interest.
We say that Ω is Li expressive if for all M∗ ∈ Ω∗ , there exists M ∈ Ω s.t. Li (M∗ ) = Li (M). ■48

It should be emphasized that expressiveness on layers higher than Layer 1 is a highly nontrivial
property (e.g., Example 1 in Appendix C.1 shows the complications involved in constructing an NCM
to replicate another SCM on all 3 layers). Even a model class that is L2 -expressive can represent
far more settings than model classes that are only L1 -expressive, since there are many more ways inwhich SCMs can differ on L2 than on L1 . Theorem 1 states that NCMs are L3 -expressive, whichleads to the question: what model classes are not L3 -expressive?
Many neural model classes are L1 -expressive, which
can be seen as the property of modeling an uniqueprobability distribution over a set of observed variables. Additionally, this model should be generative,i.e., one should be able to draw samples from themodel’s fitted distribution. Model classes that havethis property include variational models with normalizing flows [62], which are generative models and areproven to be able to fit any data distribution. It is also
believed that popular generative models like generative adversarial networks [20] have this property as
well.

SCMs (Ω∗ )Model Class (Ω)

NCMs

M
M∗

Li -Expressive:

L∗1

L∗2

L∗3

Interesting enough, being generative does not imply
PCH
being causal or counterfactual. For instance, thesemodel classes are not well defined for valuating any Figure 19: The SCM class Ω∗ is shown incausal distributions. A model from one of these the l.h.s. and another class (non-SCM) Ωclasses that is fitted on P (V) can only provide sam- class is shown in the r.h.s.. If we consider
ples from P (V). On the other hand, distributions like M ∗ ∈ Ω∗ that generates a specific PCH, Ω is
P (Vx ), the distribution of V under the intervention Li representative if there is a model M ∈ Ω∗do(X = x) for some X ⊆ V, are entirely different that exhibit the same behavior under Li .
distributions from Layer 2 of the PCH. A model fitted
on P (V) cannot output samples from P (Vx ), and it
certainly cannot output samples from every Layer 2
or Layer 3 distributions. These models, therefore, are not even L2 -expressive, let alone L3 -expressive.
It is somewhat natural, and perhaps obvious, that model classes that are not defined on higher layers
cannot be expressive on higher layers. Still, we can also consider this property on model classes
proposed by other deep learning works which include a causal component. Works such as [70]and [64] have had great success estimating higher layer quantities like average treatment effects
under backdoor/conditional ignorability conditions [58, Sec. 3.3.1]. Perhaps these models can always
succeed at modeling Layer 2 expressions as long as the ground truth can be modeled by an SCM
that also meets those same backdoor conditions. However, since there are SCMs that do not fit the
backdoor setting, we cannot say that these models are L2 or L3 -expressive. We illustrate this pointby providing an example (Example 5) in Appendix C.3, where the NCM estimates a causal quantity
in a setting that does not meet the backdoor condition.
In some way, these works and most of the literature are concerned with estimating causal effects thatare identifiable from observational data P (V ), usually in the form of the backdoor formula, whichmeans that the “causal reasoning” already happened outside the network itself. In other words, a
causal distribution Q = P (Y|do(X = x)) being identifiable means that there exists a function fsuch that Q = f (P (V )). The causal “inference” means determining from causal assumptions (forexample the causal diagram G) whether Q is identifiable, or whether f exists. Whenever this is thecase, and f has a closed-expression, the inference is done, and the task that remains is to estimate f
efficiently from finite samples obtained from P (V ).
Even though many existing works do not have the L2 or L3 -expressiveness properties, this is not
to say that the NCM is the only model class that is expressive enough to represent all the threelayers of the PCH. Consider the following example of a model class artificially constructed to be
L2 -expressive:
Definition 21 (L2 -Expression Wrapper). Let M L1 be an L1 -expressive model class such as anormalizing flow model. Denote MPL1 as a model from this class fitted on distribution P . For acollection of L2 distributions P∗ , define L2 -expression wrapper M L2 := {MPL1 : P ∈ P∗ }.
■49

It is fairly straightforward to show that the L2 -expression wrapper is L2 -expressive. For any SCM
M∗ , we can simply construct L2 -expression wrapper M L2 with P∗ = L2 (M∗ ). Then, for any
L1
L2 -query Q, M L2 answers Q by providing the distribution of MQ. In other words, we could simply
train a generative model for every L2 distribution of an SCM, and collectively, these models induce
all L2 distributions of the SCM.
Although expressive, this model is highly impractical for most practical uses. First, there are typicallytoo many distributions in Layer 2 to effectively learn all of them. A new distribution would be createdfor every possible intervention of every subset of variables. In fact, this amount grows exponentiallywith the number of variables, and in continuous cases, it is infinite.
Second, unlike the NCM data structure (Def. 7), there is no clear way to incorporate the constraintsof a CBN in the expression wrapper. Without these constraints, it is obvious that the expression
wrapper suffers from the same limitations from the CHT as NCMs (Corol. 1). Suppose we are given
P (V) from true SCM M∗ , but we are interested in the distribution P (Vx ). We could guarantee an∗11
expression wrapper M L2 such that MPL(V)= P M (V), but MPL(V
could be any distribution overx)∗

V that is consistent with x, and we would not be able to guarantee that it matches P M (Vx ).
Attempting to incorporate the constraints of a CBN in an expression wrapper would scale poorly andbe difficult to realize in practice. Consider the following example.

D

S

B

Figure 20: Causal diagram G of M∗ from Example 5.
Example 8. Consider the same setting from Example 5, where we would like to evaluate a query
like Q = P (B = 1 | do(D = 1)) given P (V) and the graph G (displayed again in Fig. 20 for
convenience). If we were using the expression wrapper, we would need an estimator for each of theL1 and L2 distributions such P (V), P (VD=1 ), P (VS=1 ), and so on.
However, unlike the NCM, the expression wrapper does not automatically incorporate the constraints
implied by G. Here is a list of some constraints used in the do-calculus derivation in Example 5:
1. P (B | do(D), S) = P (B | do(D, S))
2. P (B | do(D, S)) = P (B | do(S))
3. P (S | do(D)) = P (S | D)
4. P (D | do(S)) = P (D)5. P (B | do(S), D) = P (B | S, D)
This list is not exhaustive, and there are more constraints induced by G. This list is also compressed,
since intervening on different values for the same variables result in different distributions. Note thateven with just 3 binary variables, the number of constraints is quite long when enumerated.
Maintaining all of these constraints while fitting all of the desired distributions is the key difficulty ofusing the L2 -expression wrapper. While fitting P (V), the expression wrapper would have to also
generate some other distributions from layer 2 like P (VD=1 ), keeping constraints in mind. One
cannot make such a choice arbitrarily. For instance, setting P (VD=1 ) to P (V), but with all valuesof D set to 1, would still violate constraint 3 from the above list. This would be infeasible for any
tractable optimization procedure.
■This illustrates the benefits of the properties of the NCM. Not only is the NCM L3 -expressive, anon-trivial property to achieve, but it also is easily able to incorporate structural constraints.

50

E

Frequently Asked Questions
Q1. Why are the sets of noise variables for each function not necessarily independent in the
SCM and NCM?
Answer. Each structural causal model includes a set of observed (endogenous) and unobserved (exogenous) variables, V and U, respectively. The set U accounts for the unmodeled
sources of variation that generate randomness in the system. On the one hand, an exogenous
variable U ∈ U could affect all endogenous variables in the system. On the other hand, eachUi ∈ U could affect only one observable Vi ∈ V and be independent to all other variables
in U \ {Ui }. These two represent opposite sides of a spectrum, where the former means
zero assumptions on the presence of unobserved confounding, while the latter represents
the strongest assumption known as Markovianity. We operate in between, allowing for all
possible cases, which is represented in the causal diagram through bidirected edges.
In the context of identification, Markovianity is usually known as the lack of unobserved
confounding. As shown in Corol. 3, the identification problem becomes trivial and causationis always derivable from association in this case, i.e., all layer 2 queries are computable fromlayer 1 data. In practice, identification becomes somewhat more involved in non-Markovian
settings. Example 4 in Appendix C shows a case where a causal query is not identifiable
even in a 2 variable case. More discussion and examples can be found in [5, Sec. 1.4].
Q2. How come the true SCM cannot be learned from observational data? If the functions areuniversal approximators, this seems to be easily accomplished.
Answer. This is not possible in general, as highlighted by Corol. 1. The issue is that thec, could generate the distribution of observational data perfectly yet stilllearned model, M
differ in interventional distributions from the true SCM, M∗ . Searching for (or randomly
choosing) some SCM that matches the observational distribution will almost surely fail tomatch the interventional distributions. Since the true SCM, M∗ , is unobserved, one would
c preserve thenot be able to determine whether the inferences made on the learned model M
validity of the causal claims. See Example 2 in Appendix C for a more detailed discussion.
Q3. Why are feedforward neural networks and uniform distributions used in Def. 3? Wouldthese results not hold for other function approximators and noise distributions?
Answer. We implemented in the body of the paper NCMs with feedforward neural networks
and uniform distributions for the sake of clarity of exposition and presentation. The resultsof the NCM are not limited to this particular architecture choice, and other options may
offer different benefits in practice. A general definition of the NCM is introduced in Def. 18,
and the corresponding results in this generalized setting are provided in Appendix D.1.
Q4. What is a causal diagram? What is a CBN? Is there any difference between these objects?
Answer. A causal diagram G is a non-parametric representation of an SCM in the form of agraph, which follows Def. 12, such that nodes represent variables, a directed edge from X to
Y indicates that X is an input to fY , and a bidirected edge from X to Y indicates that there
is unobserved confounding between X and Y . The causal diagram G is strictly weaker than
the generating SCM M∗ . Talking about the diagram itself is usually ill-defined, since it isrelevant in the context of the constraints it imposes over the space of distributions generatedby M∗ (both observed and unobserved).
A Causal Bayesian Network (CBN, Def. 15) is a pair consisting of a causal diagram G and acollection of layer 2 (interventional) distributions P∗ , where the distributions follow a set of
constraints represented in the diagram (i.e., they are “compatible”). Remarkably, the causal
diagram induced by any SCM, along with its induced layer 2 distributions, together form avalid CBN (Fact 2). Causal diagrams and the constraints encoded in CBNs are often the fuelto causal inference methods (e.g., do-calculus) and used to bridge the gap between layer 1
and layer 2 quantities. We refer readers to Appendix C.2 for a further discussion on these
inductive biases and their motivation, and [5, Sec. 1.3] for further elaborations.

51

Q5. Based on the answer to Q4, it is not entirely clear what an NCM really represents. Is an
NCM a causal diagram? Or is it an SCM? Or should I think about it in a different way?
Answer An NCM is not a causal diagram, and although an NCM is technically an SCM,
by definition, it may be helpful to think of it as a separate data structure. As discussed
above, SCMs contain strictly more information than causal diagrams. Still, NCMs without
G-consistency (Def. 5) do not even ascertain the constraints represented in G about layer 2
distributions. So, even though an NCM seems to appear like an SCM, it is an “empty” data
structure on its own. Whenever we impose G-consistency, NCMs may have the capability ofgenerating interventional distributions, contingent on L1 -consistency and the identifiability
status of the query.
More broadly, we think it is useful to think about an NCM as a candidate for a proxy modelfor the true SCM. Unlike the SCM, the NCM’s concrete definitions for functions andnoise allow the NCM to be optimized (via neural optimization procedures) for learning inpractical settings. One additional difference between the NCM and SCM is their purposein causal inference. The SCM data structure is typically used to represent reality, so insome sense, the SCM has all information of interest from all layers of the PCH. Of course,
this reality is unobserved, so the SCM is typically unavailable for use. The NCM is thentrained as a proxy for the true SCM, so it has all of the functionality of an SCM while being
readily available. However, unlike the SCM, the “quality” of the information in the NCM isdependent on the amount of input information. If an NCM is only trained on data from layer
1, the Neural CHT (Corol. 1) says that distributions induced by the NCM from higher layers
will, in general, be incorrect. For that reason, while the NCM has the same interface as the
SCM for the PCH, the NCM’s higher layers may be considered “underdetermined”, in thesense that they do not contain any meaningful information about reality.
Q6. Why do you assume the causal diagram exists instead of learning it? What if the causal
diagram is not available?
Answer.
As implied by the N-CHT (Corol. 1), cross-layer inferences cannot be
accomplished in the general case without additional information. In other words, the causal
diagram assumption is out of necessity. In general, one cannot hope to learn the wholecausal diagram from observational data either. However, it is certainly not the case thatthe causal diagram will always be available in real world settings. In such cases, otherassumptions may be necessary which may help structural learning, or perhaps the causal
diagram can be partially specified to a degree that allows answering the query of interest(see also Footnotes 6 and 7).
Q7. Are NCMs assumed to be acyclic?
Answer. We assume for this work that the true SCM M∗ is recursive, meaning thatthe variables can be ordered in a way such that if Vi < Vj , then Vj is guaranteed to not
be an input to fVi . This implies that the causal diagram induced by M∗ is acyclic, so
G-constrained NCMs (from Def. 7) must also be recursive. That said, not all works makethe recursive assumption, so the general definition of NCMs does not need to be constrained
a priori.
Q8. Why is M∗ assumed to be an SCM instead of an NCM in the definition for neural identifiability (Def. 8)?
Answer. M∗ indicates the ground truth model of reality, and we assume that reality ismodeled by an SCM, without any constraints in the form of the functions or probability overthe exogenous variables. The NCM is a data structure that we constructed to solve causal
inference problems, but the inferences of interest are those from the true model. For thisreason, several results were needed to connect the properties of NCMs to those from SCMs,
including Thm. 2 (showing that NCMs can encode the same constraints as SCMs’ causal
diagrams) and Thm. 3 (showing that NCMs can represent any G-consistent SCM on layer 2).
These results are required to show the validity (or meaning) of the inferences made from theNCM, which otherwise would have no connection to the true model, M∗ .
Naturally, checking for identifiability within the space of NCMs defeats the purpose of thework since the model of interest is not (necessarily) an NCM. Conveniently, however, the52expressiveness of the NCM (as shown in Thm. 3) shows that if two SCMs agree on P (V)and G but do not agree on P (y | do(x)), then there must also be two NCMs that behave
similarly. This means that attempting to check for identifiability in the space of NCMs willproduce the correct result, which is why Alg. 1 can be used. Still, interestingly, this may nolonger be the case within a less expressive model class (see Example 7 in Appendix C.3).
Q9. What is the purpose of Thm. 3 if we already have Thm. 1?
Answer. While Thm. 1 shows that NCMs (from Def. 3) can express any SCM on all threelayers of the PCH, it does not make any claims about G-constrained NCMs (Def. 7). In fact,a G-constrained NCM is obviously incapable of expressing any SCM that is not G-consistent.
Thm. 3 emphasizes that even when encoding the structural constraints in G (CBN-like),
NCMs are still capable of expressing any SCM that is also compatible with G. If thisproperty did not hold, it would not always be possible to use the NCM as a proxy for the
SCM, since there may be some SCMs that are G-consistent, but there does not exist an NCM
that matches the corresponding distributions.
One important subtlety of Thm. 3 is that the expressiveness is described after applying theconstraints of G. It may be relatively simple to use a universal approximator to constructa model class that can express any SCM on layer 2, such as the L2 -expression wrapper(Def. 21 from Appendix D.2). However, the L2 -expression wrapper does not naturally
enforce the constraints of G. Incorporating such constraints is nontrivial, and even if
the constraints were applied, the model class may no longer retain its expressiveness.
Thm. 3 shows that the NCM is the maximally expressive model class that still respects theconstraints of G.
Q10. The objective function in Eq. 5 is not entirely clear. What role does λ play?
Answer. The purpose of Alg. 2 is to solve the optimization problem in lines 2 and 3 ofAlg. 1. The goal can be described in two parts: maximize/minimize a query of interest, likeP (y | do(x)), while simultaneously learning the observational distribution P (V). This isa nontrivial optimization problem, and there are many different ways to approach it. The
proposed method penalizes both of these quantities in the objective. The first term of Eq. 5
attempts to maximize log-likelihood, while the second term attempts to maximize/minimize
P (y | do(x)). Certainly, we do not want the optimization of the second term to affectthe optimization of the first term, since we need accurate learning of P (V) to make any
deductions on the identifiability status of P (y | do(x)) and subsequent estimation of it.
Further, the hyperparameter λ is used to balance the amount of attention placed on
maximizing/minimizing P (y | do(x)). If λ is too small, then the term would be ignored,
and the optimization of P (y | do(x)) could fail even in non-ID cases. On the other
hand, if λ is too large, the optimization procedure might attempt to maximize/minimize
P (y | do(x)) at the expense of learning P (V) properly, which may result in incorrect
inferences in ID cases. Our solution starts λ at a large value to allow the optimization toquickly find parameters that maximize/minimize P (y | do(x)), and then it lowers λ astraining progresses so that P (V) is learned accurately by the end of training.
Q11. Why would one want, or prefer, to solve identifiability using NCMs? Would it not be easier
to use existing results (e.g., do-calculus) to determine the identifiability of a query, then use
the NCM for estimation?
Answer. We provide a more detailed discussion on this topic in Appendix C.4. In summary, when solving causal problems like identification or estimation, we introduced a newframework using NCMs where one can construct a proxy model to mimic the true SCM via
neural optimization. Meanwhile, existing works focus on solving the problems at a higherlevel of abstraction with the causal diagram, ignoring the true SCM. We call these works“symbolic” since they directly use the constraints of the causal diagram to algorithmicallyderive a solution. We are not deciding for the causal analyst which method to use whencomparing symbolic and optimization-based methods. For instance, we developed Alg. 4 asan alternative to Alg. 1 for researchers who would prefer to use a symbolic approach for
identification while using an NCM for estimation.
53

We note that the identification and estimation tasks typically appear together in practice,and it is remarkable that the proxy-model framework with NCMs is capable of solving
the entire causal pipeline. In some sense, the identification task provides the causal
reasoning required to perform estimation. Once a query is determined to be identifiable, theestimation task is only a matter of fitting an expression. It may be somewhat unsurprisingthat the expressiveness of neural networks along with its strong optimization results allow
it to fit any expression, but this work shows, for the first time, that neural nets are also
capable of performing the causal reasoning required to determine identifiability. We notethat Alg. 1 describes a procedure for solving the ID problem that is unique compared tosymbolic approaches. Our goal with Alg. 1 is to provide insights to alternative approaches
to causal problems under the proxy model framework compatible with optimization methods.
Q12. Why would one want to learn an entire SCM to solve the estimation problem for a specificquery? Shouldn’t the efforts be focused on estimating just the query of interest?
Answer. Indeed, existing works typically focus on a single interventional distribution andalso abstract out the SCM, as shown in Fig. 15. In particular, solutions to the identification
problem typically derive an expression for the query of interest using the causal diagram,and solutions to the estimation problem directly evaluate the derived expression.
One of the novelties of this work is the introduction of a method of solving these tasks
using a proxy model of the SCM. Compared to existing methods, there are a number ofreasons one may want to have a proxy model. For instance, one may want to have generative
capabilities of both layer 1 and identifiable layer 2 distributions rather than simply obtaining
a probability value. We refer readers to Appendix C.4 for a more detailed discussion.
Q13. It appears that the theory and results only hold if learning is perfect. What happens if there
is error in training?
Answer. This work does not make any formal claims regarding cases with error in training.
Still, one of our goals with the experiments of Sec. 5 is to show empirically that results
tend to be fairly accurate if training error is minimized to an acceptable degree (i.e.,
L1 -consistency nearly holds). A more refined understanding and detailed theoreticalanalysis of robustness to training error is an interesting direction for future work.

54