def testConvertBetweenInteger(self):
try:
# Make sure converting to between integer types scales appropriately
with self.test_session():
self._convert([0, 255], dtypes.uint8, dtypes.int16, [0, 255 * 128])
self._convert([0, 32767], dtypes.int16, dtypes.uint8, [0, 255])
# itensor is tf.int32, but attr "T" is set to tf.int16
except:
import pdb;
pdb.post_mortem()
评论列表
文章目录