Returns the input dataset, which should produce per-feed logical batches. Each batch is a pytree of arrays which reside on host memory (i.e., leaves can be any array type which can be converted to numpy via `as_numpy_array`). The dataset should be iterable, i.e., it is expe
(self)
| 189 | ) |
| 190 | |
| 191 | def dataset(self) -> Iterable[Nested[Tensor]]: |
| 192 | """Returns the input dataset, which should produce per-feed logical batches. |
| 193 | |
| 194 | Each batch is a pytree of arrays which reside on host memory (i.e., leaves can be any array |
| 195 | type which can be converted to numpy via `as_numpy_array`). |
| 196 | |
| 197 | The dataset should be iterable, i.e., it is expected to support conversion to an iterator |
| 198 | via `iter(...)`. Although not strictly required, it is recommended for the iterator to be |
| 199 | checkpointable. |
| 200 | """ |
| 201 | raise NotImplementedError(type(self)) |
| 202 | |
| 203 | def __iter__(self) -> Iterator[Nested[Tensor]]: |
| 204 | """Iterates over the input dataset. |
no outgoing calls