如何使用与attention_ocr的FSNS数据集相同的格式创建数据集?

时间:2018-06-15 09:16:48

标签: python tensorflow attention-model

我在How to create dataset in the same format as the FSNS dataset?

中尝试使用代码进行回答

对于图像类我收到以下错误:

File "createFsns.py", line 101, in 'image/class': _int64_feature(char_ids_padded), File "createFsns.py", 
line 52, in _int64_feature return tf.train.Feature(int64_list=tf.train.Int64List(value=[value]))
TypeError: [20, 10, 0, 2, 10, 15, 0, 1, 1, 3] has type list, but expected one of: int, long

我已将tf.train.Feature(int64_list=tf.train.Int64List(value=[value])更正为tf.train.Feature(int64_list=tf.train.Int64List(value=value)现在收到此错误:

tf.train.Feature(int64_list=tf.train.Int64List(value=value)) TypeError: Value must be iterable

0 个答案:

没有答案