Skip to content
This repository has been archived by the owner on Jul 7, 2023. It is now read-only.

Commit

Permalink
Do not require preprocess_resize_frames in hparams for VideoProblem
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 207295010
  • Loading branch information
Ryan Sepassi authored and Copybara-Service committed Aug 3, 2018
1 parent ac8f6e3 commit 927f78c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tensor2tensor/data_generators/video_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def use_not_breaking_batching(self):

def preprocess_example(self, example, mode, hparams):
"""Runtime preprocessing, e.g., resize example["frame"]."""
if hparams.preprocess_resize_frames is not None:
if getattr(hparams, "preprocess_resize_frames", None) is not None:
example["frame"] = tf.image.resize_images(
example["frame"],
hparams.preprocess_resize_frames,
Expand Down

0 comments on commit 927f78c

Please sign in to comment.