AutoNormal
, AutoDelta
, and AutoGuideList
do not support subsamples of variable size.
#1739
Labels
enhancement
New feature or request
Milestone
AutoNormal
,AutoDelta
, andAutoGuideList
raise an exception in SVI when the subsample size varies across differentlog_density
evaluation. Here is an example reproducing the issue (run onmaster
).The traceback for the failed call is as follows.
I think the issue is that these guides use
_create_plates
which in turn uses prototype traces to determine the subsample size.numpyro/numpyro/infer/autoguide.py
Lines 108 to 113 in aec6bd5
The prototype traces are of course only created on the first invocation such that there is a discrepancy in the expected subsample size when a different mini-batch size is used. Guides inheriting from
AutoContinuous
do not call_create_plates
and do not use plates in their__call__
method. I couldn't quite figure out why some guides do and some guides don't.The text was updated successfully, but these errors were encountered: