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

Code can't run #14

Open
Mrwang989 opened this issue Dec 13, 2021 · 0 comments
Open

Code can't run #14

Mrwang989 opened this issue Dec 13, 2021 · 0 comments

Comments

@Mrwang989
Copy link

Hi,
When I ran the code again, a similar problem occurred. I want to know how to solve it, that would be greatly appreciated.
Traceback (most recent call last):
File "C:/Users/57282/Desktop/land-cover-master/run.py", line 203, in
main()
File "C:/Users/57282/Desktop/land-cover-master/run.py", line 145, in main
train.run_experiment()
File "C:\Users\57282\Desktop\land-cover-master\landcover\train_model_landcover.py", line 441, in run_experiment
model = self.get_model()
File "C:\Users\57282\Desktop\land-cover-master\landcover\train_model_landcover.py", line 378, in get_model
model = models.unet(self.input_shape, self.classes, optimizer, self.loss)
File "C:\Users\57282\Desktop\land-cover-master\landcover\models.py", line 115, in unet
return make_model(i, o, optimizer, loss)
File "C:\Users\57282\Desktop\land-cover-master\landcover\models.py", line 168, in make_model
model.compile(
File "E:\Anaconda\envs\land_cover\lib\site-packages\tensorflow\python\keras\engine\training.py", line 565, in compile
self._validate_compile(optimizer, metrics, **kwargs)
File "E:\Anaconda\envs\land_cover\lib\site-packages\tensorflow\python\keras\engine\training.py", line 2626, in _validate_compile
raise ValueError(
ValueError: Variable (<tf.Variable 'conv2d/kernel:0' shape=(3, 3, 4, 64) dtype=float32, numpy=
array([[[[-0.05316697, 0.01695759, 0.06781096, ..., 0.04036037,
-0.02615297, -0.05482 ],
[-0.03512351, 0.00207546, 0.08749197, ..., -0.03793961,
-0.0256898 , -0.02477491],
[-0.02103255, -0.02145103, -0.09544748, ..., 0.08490782,
0.00683988, -0.00993489],
[ 0.07889044, 0.03161094, -0.02841607, ..., 0.07148486,
-0.08556601, 0.01502845]],

    [[ 0.02166805, -0.0465791 ,  0.03786724, ..., -0.05684982,
      -0.02745763, -0.02497146],
     [-0.0321082 , -0.07753698,  0.08001576, ...,  0.03958925,
      -0.01430742,  0.07854632],
     [ 0.03598402, -0.009101  , -0.08477397, ...,  0.04529131,
      -0.0007516 ,  0.07106098],
     [-0.01125589,  0.02705219, -0.02472276, ...,  0.01507821,
      -0.086858
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