-
I would like to thank the authors and contributors of this wonderful AutoML system. input_node1 = ak.ImageInput()
output_node = ak.Normalization()(input_node1)
output_node = ak.ImageAugmentation()(output_node)
output_node1 = ak.ConvBlock()(output_node)
output_node2 = ak.ResNetBlock(version="v2")(output_node)
output_node1 = ak.Merge()([output_node1, output_node2])
input_node2 = ak.StructuredDataInput()
output_node = ak.CategoricalToNumerical()(input_node2)
output_node2 = ak.DenseBlock()(output_node)
output_node = ak.Merge()([output_node1, output_node2])
output_node1 = ak.ClassificationHead()(output_node)
output_node2 = ak.RegressionHead()(output_node)
auto_model = ak.AutoModel(
inputs=[input_node1, input_node2],
outputs=[output_node1, output_node2],
overwrite=True,
max_trials=2,
)
image_data = np.random.rand(num_instances, 32, 32, 3).astype(np.float32)
structured_data = np.random.rand(num_instances, 20).astype(np.float32)
regression_target = np.random.rand(num_instances, 1).astype(np.float32)
classification_target = np.random.randint(5, size=num_instances)
auto_model.fit(
[image_data, structured_data],
[classification_target, regression_target],
batch_size=32,
epochs=3,
) Can we load two input data with python generators and process each branch of them separately? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
After searching and trying I reached the answer. I will put it here so it may help someone. I suggest adding it to the tutorial :).
|
Beta Was this translation helpful? Give feedback.
After searching and trying I reached the answer. I will put it here so it may help someone. I suggest adding it to the tutorial :).
here is an update to the generator displayed in the tutorial here If you have multiple inputs x and s: