From 8e444ab2ad4dcbec48c1fe775c4512fa4ed390a3 Mon Sep 17 00:00:00 2001 From: ProGamerGov Date: Thu, 5 Jan 2017 18:21:23 -0700 Subject: Replaced outdated tf.pack with tf.stack This resolves the issue posted in https://github.com/cysmith/neural-style-tf/issues/18. tf.pack was replaced by tf.stack in 2016. --- neural_style.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neural_style.py b/neural_style.py index 8d40e1b..be5a95e 100644 --- a/neural_style.py +++ b/neural_style.py @@ -380,8 +380,8 @@ def mask_style_layer(a, x, mask_img): tensors = [] for _ in range(d.value): tensors.append(mask) - mask = tf.pack(tensors, axis=2) - mask = tf.pack(mask, axis=0) + mask = tf.stack(tensors, axis=2) + mask = tf.stack(mask, axis=0) mask = tf.expand_dims(mask, 0) a = tf.mul(a, mask) x = tf.mul(x, mask) -- cgit v1.2.3-70-g09d2