Skip to content

Commit 34faba4

Browse files
Neural-Link Teamtensorflow-copybara
authored andcommitted
Remove id feature from input
PiperOrigin-RevId: 414539389
1 parent 22687eb commit 34faba4

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

neural_structured_learning/examples/graph_keras_mlp_cora.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,16 +125,13 @@ def parse_example(example_proto):
125125
nbr_feature_key = '{}{}_{}'.format(NBR_FEATURE_PREFIX, i, 'words')
126126
nbr_weight_key = '{}{}{}'.format(NBR_FEATURE_PREFIX, i,
127127
NBR_WEIGHT_SUFFIX)
128-
nbr_id_key = '{}{}_{}'.format(NBR_FEATURE_PREFIX, i, 'id')
129128
feature_spec[nbr_feature_key] = tf.io.FixedLenFeature(
130129
[hparams.max_seq_length],
131130
tf.int64,
132131
default_value=tf.constant(
133132
0, dtype=tf.int64, shape=[hparams.max_seq_length]))
134133
feature_spec[nbr_weight_key] = tf.io.FixedLenFeature(
135134
[1], tf.float32, default_value=tf.constant([0.0]))
136-
feature_spec[nbr_id_key] = tf.io.FixedLenFeature(
137-
(), tf.string, default_value='')
138135

139136
features = tf.io.parse_single_example(example_proto, feature_spec)
140137

0 commit comments

Comments
 (0)