Neural Networks
We now consider learner and critic classes represented by neural networks. The
joint estimator implemented by AGMM2L2 approximately solves
Here, \(A\) and \(B\) are the inputs to the first and second bridge functions, while \(D\) and \(C\) are the instruments for the first and second moment equations. The multiplier \(W\) defaults to one. Thus the first critic targets the residual \(g(A)-Y\), and the second targets \(h(B)-Wg(A)\).
The learner_norm_reg argument supplies the common coefficient \(\mu\)
on the empirical squared learner outputs. This is distinct from
learner_l2 and adversary_l2, which apply weight decay to network
parameters during optimization. The minimax problem is trained with the
Optimistic Adam algorithm of Daskalakis et al. (2017), as proposed for adversarial conditional
moment estimation by Dikkala et al. (2020).
|
Implements optimistic Adam algorithm. |
Subsetted Estimator
With subsetted=True, subset_ind1 and subset_ind2 select the
observations used for the first and second moment equations. If their sizes are
\(p\) and \(q\), the corresponding masked full-sample losses are scaled
by \(n/p\) and \(n/q\). This is equivalent to averaging each moment
loss over its own subset. The empirical-L2 penalties remain full-sample
averages.
Both indicators must be binary and nonempty. If subset_ind2 is omitted,
the complement of subset_ind1 is used. When both indicators are supplied,
they need not form a partition.
Predictions
AGMM2L2.predict returns (h(B), g(A)). By default, each prediction is
averaged across saved epochs after an optional burn-in. A final model or a
specific epoch can also be selected. If alpha is supplied for an averaged
prediction, the additional quantiles summarize variation across retained
epochs; they are heuristic stability bands, not sampling confidence
intervals.
Single estimator
|
Adversarial Generalized Method of Moments estimator. |
|
AGMM with kernel layer using Maximum Mean Discrepancy. |
|
AGMM with centroid-based Maximum Mean Discrepancy. |
|
AGMM with kernel loss. |
|
AGMM with Maximum Mean Discrepancy. |
Joint estimator
|
Joint adversarial estimator for nested NPIV with empirical-L2 regularization. |