Created
July 15, 2018 11:10
-
-
Save securetorobert/ad9622e151675bee9b6c65d71a2bc4e4 to your computer and use it in GitHub Desktop.
Create a numeric feature column
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Defaults to a tf.float32 scalar. | |
numeric_feature_column = tf.feature_column.numeric_column(key="SepalLength") | |
# Represent a tf.float64 scalar. | |
numeric_feature_column = tf.feature_column.numeric_column(key="SepalLength", | |
dtype=tf.float64) | |
# Represent a 10-element vector in which each cell contains a tf.float32. | |
vector_feature_column = tf.feature_column.numeric_column(key="Bowling", | |
shape=10) | |
# Represent a 10x5 matrix in which each cell contains a tf.float32. | |
matrix_feature_column = tf.feature_column.numeric_column(key="MyMatrix", | |
shape=[10,5]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment