jmiller656 / discogan-tensorflow Goto Github PK
View Code? Open in Web Editor NEWAn implementation of DiscoGAN in tensorflow
License: MIT License
An implementation of DiscoGAN in tensorflow
License: MIT License
Hello,
I am getting the following error while running:
File "main.py", line 5, in
g = utils.generator(a)
File "/Users/haosun/Raju/DiscoGAN-Tensorflow-master/utils.py", line 135, in generator
conv_t_1 = conv_layer_t(conv_4,[4,4,im_size,int(conv_4.get_shape()[-1])],[im_size],[tf.shape(x)[0],im_size/8,im_size/8,im_size],activation=lrelu,batch_norm=g_bn3,name="g_deconv_1",reuse=reuse)
File "/Users/haosun/Raju/DiscoGAN-Tensorflow-master/utils.py", line 75, in conv_layer_t
h = conv2d_t(x,w,shape)+b
File "/Users/haosun/Raju/DiscoGAN-Tensorflow-master/utils.py", line 29, in conv2d_t
return tf.nn.conv2d_transpose(x,w,shape,strides=[1,stride,stride,1],padding=padding)
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/ops/nn_ops.py", line 1024, in conv2d_transpose
output_shape_ = ops.convert_to_tensor(output_shape, name="output_shape")
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 676, in convert_to_tensor
as_ref=False)
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 741, in internal_convert_to_tensor
ret = conversion_func(value, dtype=dtype, name=name, as_ref=as_ref)
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py", line 919, in _autopacking_conversion_function
return _autopacking_helper(v, inferred_dtype, name or "packed")
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py", line 881, in _autopacking_helper
constant_op.constant(elem, dtype=dtype, name=str(i)))
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/framework/constant_op.py", line 102, in constant
tensor_util.make_tensor_proto(value, dtype=dtype, shape=shape, verify_shape=verify_shape))
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/framework/tensor_util.py", line 374, in make_tensor_proto
_AssertCompatible(values, dtype)
File "/Users/haosun/Raju/anaconda/lib/python3.6/site-packages/tensorflow/python/framework/tensor_util.py", line 302, in _AssertCompatible
(dtype.name, repr(mismatch), type(mismatch).name))
TypeError: Expected int32, got 8.0 of type 'float' instead.
Could you help to provide a fix? Seems we need to typecast specifically
Hi @jmiller656 , I am playing around with DiscoGAN and thanks for letting me experimenting with it using your examples.
Are you looking forward to make this project more stable or are you planning this as a one-off project?
Hey,
Just wanted to confirm how to interpret the results. Does the image generated in generator a -> b , say img0.jpg mean that it is translating the image 000001.jpg from the celebA dataset from a female to male?
Well, in case of two custom datasets, say A and B, what does the generated image say img140.jpg signify?
Regards,
Raju
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.