ak.layout.ArrayGenerator¶
An ArrayGenerator takes a Python callable, arguments, and optionally
an expected ak.forms.Form and/or length
.
It can only be used in a ak.layout.VirtualArray to generate arrays.
If a ak.forms.Form is given, there are fewer circumstances in which the generator would need to be executed, but it is an error if the generated array does not match this ak.forms.Form.
If a length
is given (as a non-negative
int), there are fewer circumstances in which the generator would
need to be executed, but it is an error if the generated array does
not match this length
.
ak.layout.ArrayGenerator.__init__¶
- ak.layout.ArrayGenerator.__init__(callable, args=(), kwargs={}, form=None, length=None)¶
ak.layout.ArrayGenerator.__call__¶
- ak.layout.ArrayGenerator.__call__()¶
Generates the array and checks it against the ak.forms.Form and
length
, if given.