Open johnsGuo opened 2 years ago
example = tf.train.Example(features=tf.train.Features(feature={ 'dense_input': tf.train.Feature(float_list=tf.train.FloatList(value=dense)), 'sparse_ids_input': tf.train.Feature(int64_list=tf.train.Int64List(value=feat_ids)), 'sparse_wgt_input': tf.train.Feature(float_list=tf.train.FloatList(value=feat_vals)), 'seq_50_input': tf.train.Feature(int64_list=tf.train.Int64List(value=seq_50)), 'is_click': tf.train.Feature(int64_list=tf.train.Int64List(value=[int(labels)])), }))
writer.write(example.SerializeToString())
What error do you see when trying to load this TFRecord file into the What-If Tool? If running through TensorBoard, you may see errors in the running log on the console that launched the TensorBoard job.
example = tf.train.Example(features=tf.train.Features(feature={ 'dense_input': tf.train.Feature(float_list=tf.train.FloatList(value=dense)), 'sparse_ids_input': tf.train.Feature(int64_list=tf.train.Int64List(value=feat_ids)), 'sparse_wgt_input': tf.train.Feature(float_list=tf.train.FloatList(value=feat_vals)), 'seq_50_input': tf.train.Feature(int64_list=tf.train.Int64List(value=seq_50)), 'is_click': tf.train.Feature(int64_list=tf.train.Int64List(value=[int(labels)])), }))
writer.write(example.SerializeToString())