R/DataGenerators.R
combine_generators.Rd
Creates a Python Class that internally iterates over the data.
Generators can e.g. come from make_generator_from_dataframe
or
from keras::flow_images_from_dataframe
.
Need to have equal batch size, and optionally equal seeds if shuffling is used.
Returns batches of the following form:
list(
list(X1_batch, X2_batch),
Y_batch
)
or where Y_batch
is Y1_batch, Y2_batch if both gen._y
are TRUE
, else just
e.g. Y1_batch (default).
combine_generators(gen1, gen2, gen1_y = TRUE, gen2_y = FALSE)
gen1 |
|
---|---|
gen2 |
|
gen1_y |
|
gen2_y |
|