image_read_utils.py 文件源码

python
阅读 25 收藏 0 点赞 0 评论 0

项目:ActionVLAD 作者: rohitgirdhar 项目源码 文件源码
def decode_flow(img_str):
  # IMPORTANT NOTE: I am now resizing the flow frames before running through
  # the preprocessing. I was not doing that earlier (in the master). This leads
  # to the 66 number to drop to 63 on HMDB. But it should be fixable by
  # re-training with this setup
  with tf.variable_scope('decode_flow_frame'):
    img = tf.concat(2, [tf.image.decode_jpeg(el, channels=1)
      for el in tf.unpack(img_str)])
    # Always convert before resize, this is a bug in TF
    # https://github.com/tensorflow/tensorflow/issues/1763
    img = tf.image.convert_image_dtype(img, dtype=tf.float32)
    img = tf.image.resize_images(img, [IM_HT, IM_WD])
  return [img]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号