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

BatchNormalization Error when installing #5

Open
brittanyflounders opened this issue May 20, 2023 · 2 comments
Open

BatchNormalization Error when installing #5

brittanyflounders opened this issue May 20, 2023 · 2 comments

Comments

@brittanyflounders
Copy link

I've been installing the program and all the prerequisites like this:
https://www.python.org/ftp/python/3.10.11/python-3.10.11-amd64.exe
pip install pyqt5
pip install opencv-python
pip install tensorflow

but this is the latest error message I get, and I don't know how to fix it:
Traceback (most recent call last):
File "C:\Users\user\Desktop\Image-Enhancer-master\run.py", line 1, in
from AppWindowQt import Ui_MainWindow
File "C:\Users\user\Desktop\Image-Enhancer-master\AppWindowQt.py", line 4, in
from AppGuiFunctions import GuiFunctions
File "C:\Users\user\Desktop\Image-Enhancer-master\AppGuiFunctions.py", line 5, in
from EnhancerGANModel import DeepLearningGANModels
File "C:\Users\user\Desktop\Image-Enhancer-master\EnhancerGANModel.py", line 3, in
from model.srgan import generator as srgangenerator
File "C:\Users\user\Desktop\Image-Enhancer-master\model\srgan.py", line 1, in
from tensorflow.python.keras.layers import Add, BatchNormalization, Conv2D, Dense, Flatten, Input, LeakyReLU, PReLU, Lambda
ImportError: cannot import name 'BatchNormalization' from 'tensorflow.python.keras.layers' (C:\Python39\lib\site-packages\tensorflow\python\keras\layers_init_.py)

@AnMnv
Copy link

AnMnv commented Jul 3, 2023

Same here

@prathikpaip
Copy link

Import it as
"from tensorflow.python.layers.normalization import BatchNormalization"

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

3 participants