tf.keras.preprocessing.image.NumpyArrayIterator
Итератор, возвращающий данные из массива NumPy.
Наследуется от: Iterator, PyDataset
tf.keras.preprocessing.image.NumpyArrayIterator(
x,
y,
image_data_generator,
batch_size=32,
shuffle=False,
sample_weight=None,
seed=None,
data_format=None,
save_to_dir=None,
save_prefix='',
save_format='png',
subset=None,
ignore_class_split=False,
dtype=None
)
УСТЕРЕЖЕН.
| Атрибуты | |
|---|---|
max_queue_size | |
num_batches | Количество партий в PyDataset. |
use_multiprocessing | |
workers | |
Методы
on_epoch_end
on_epoch_end()
Метод, вызываемый в конце каждой эпохи.
reset
reset()
__getitem__
__getitem__(
idx
)
Получает партию по позиции index.
| Аргументы | |
|---|---|
index | Позиция партии в PyDataset. |
| Возвращаемое значение | |
|---|---|
| Партия |
__iter__
__iter__()
__len__
__len__()
| Переменные класса | |
|---|---|
| white_list_formats | ('png', 'jpg', 'jpeg', 'bmp', 'ppm', 'tif', 'tiff') |
© 2022 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 4.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/api_docs/python/tf/keras/preprocessing/image/NumpyArrayIterator