Hi everyone,
I just started studying tensorflow recently and I am using a lot of resources and books on the internet.
I am familiarizing myself with shapes in a network, I actually have a good grasp of input shape when dealing with images: (28, 28) for one channel images, and (28,28,3) for RGB images (with three color channels)
However, when dealing with rectangular data (read from a CSV) I am a little bit confused
In the code below., I know that the [5]
means 5 numerical features and [1]
means 1 categorical feature only, my code works when training a model.
num_input = tf.keras.layers.Input(shape=[5], name='num')
cat_input = tf.keras.layers.Input(shape=[1], dtype=tf.string, name='cat')
However, the below still works when I replaced [1]
with empty []
cat_input = tf.keras.layers.Input(shape=[1], dtype=tf.string, name='cat')
What does empty []
means? Could you give me some sort of explanation here that could be easily understood?
Thank you so much!