Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dense layer issue #5

Open
vcvishal opened this issue May 3, 2019 · 1 comment
Open

dense layer issue #5

vcvishal opened this issue May 3, 2019 · 1 comment

Comments

@vcvishal
Copy link

vcvishal commented May 3, 2019

model = models.Unet(height,width, loss=loss, optimizer = optimizer, metrics = metrics, fc_size = fc_size, channels=n_channels)

File "C:\Users\vcvis\Desktop\isic-2017-segmentation-master\models.py", line 47, in Unet
fc = Dense(128nn, activation='relu')(fc)
File "D:\miniconda\lib\site-packages\keras\engine\topology.py", line 558, in call
self.build(input_shapes[0])
File "D:\miniconda\lib\site-packages\keras\layers\core.py", line 827, in build
constraint=self.kernel_constraint)
File "D:\miniconda\lib\site-packages\keras\legacy\interfaces.py", line 88, in wrapper
return func(*args, **kwargs)
File "D:\miniconda\lib\site-packages\keras\engine\topology.py", line 391, in add_weight
weight = K.variable(initializer(shape), dtype=dtype, name=name)
File "D:\miniconda\lib\site-packages\keras\initializers.py", line 208, in call
dtype=dtype, seed=self.seed)
File "D:\miniconda\lib\site-packages\keras\backend\tensorflow_backend.py", line 3379, in random_uniform
dtype=dtype, seed=seed)
File "D:\miniconda\lib\site-packages\tensorflow\python\ops\random_ops.py", line 242, in random_uniform
rnd = gen_random_ops.random_uniform(shape, dtype, seed=seed1, seed2=seed2)
File "D:\miniconda\lib\site-packages\tensorflow\python\ops\gen_random_ops.py", line 712, in random_uniform
name=name)
File "D:\miniconda\lib\site-packages\tensorflow\python\framework\op_def_library.py", line 609, in _apply_op_helper
param_name=input_name)
File "D:\miniconda\lib\site-packages\tensorflow\python\framework\op_def_library.py", line 60, in _SatisfiesTypeConstraint
", ".join(dtypes.as_dtype(x).name for x in allowed_list)))
TypeError: Value passed to parameter 'shape' has DataType float32 not in list of allowed values: int32, int64

@vcvishal
Copy link
Author

vcvishal commented May 3, 2019

how to solve it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant