Skip to content

Commit

Permalink
Data copy_compatible_to TODO replace dim tag
Browse files Browse the repository at this point in the history
  • Loading branch information
albertz committed Mar 5, 2022
1 parent ae72420 commit fca3def
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions returnn/tf/util/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -3847,6 +3847,7 @@ def copy_replace_dim_tag(self, axis, new_dim_tag):
mask_t = mask.placeholder # [T,B], e.g. [1,0,1] (ignoring batch-dim for example)
# Also see UnmaskLayer.
idxs = tf.cumsum(tf.cast(mask_t, tf.int32), axis=0) # [T,B], e.g. [1,1,2]
# TODO need to get initial ... how?
initial_bc = tf.reshape(0., shape=[1] * self.batch_ndim) # add bc dims
src = self
if axis != 0:
Expand Down

0 comments on commit fca3def

Please sign in to comment.