hanzhanggit / StackGAN

MIT License
1.86k stars 455 forks source link

Prettytensor library doesn't include customs_fully_connected/custom_conv2d #31

Open KelvinBull opened 6 years ago

KelvinBull commented 6 years ago

the part of the code in StageI/model.py as followed: node1_0 =\ (pt.wrap(z_var). flatten(). custom_fully_connected(self.s16 self.s16 self.gf_dim 8). fc_batch_norm(). reshape([-1, self.s16, self.s16, self.gf_dim 8])) node1_1 = \ (node1_0. custom_conv2d(self.gf_dim 2, k_h=1, k_w=1, d_h=1, d_w=1). conv_batch_norm(). apply(tf.nn.relu). custom_conv2d(self.gf_dim 2, k_h=3, k_w=3, d_h=1, d_w=1). conv_batch_norm(). apply(tf.nn.relu). custom_conv2d(self.gf_dim * 8, k_h=3, k_w=3, d_h=1, d_w=1). conv_batch_norm())

I'm trying to running the experiments with the data.However, it gives me the error: NO module "custom_fully_connected" It might be caused by the fact that I use recent version of Tensorflow or PrettyTensor master branch . I wonder which modification make running this code on current settings. 谢谢你的解答,在线急。

akhilvasvani commented 5 years ago

If your TensorFlow version is > 1.0, then yes the custom_fully_connected will not work with PrettyTensor. If you are trying to run this code the way it is, I would suggest either downgrading your TensorFlow or use my code for TensorFlow > 1.0