tensorflow提示出错'module' object has no attribute 'pack'

编译旧的代码,会像下面这样提示出错:

deconv_shape3 = tf.pack([shape[0], shape[1], shape[2], NUM_OF_CLASSESS])

AttributeError: 'module' object has no attribute 'pack'

因为TF后面的版本修改了这个函数的名称,把tf.pack改为 tf.stack。

因此只需要替换掉,就可以编译通过了。