I am getting below error after executing the above command
import pixellib
from pixellib.tune_bg import alter_bg
ImportError Traceback (most recent call last)
C:\Users\GIRISH~1\AppData\Local\Temp/ipykernel_14768/2708208855.py in
1 import pixellib
----> 2 from pixellib.tune_bg import alter_bg
~\anaconda3\lib\site-packages\pixellib\tune_bg__init__.py in
2 import numpy as np
3 from PIL import Image
----> 4 from pixellib.semantic.deeplab import Deeplab_xcep_pascal
5 from pixellib.semantic import obtain_segmentation
6 import cv2
~\anaconda3\lib\site-packages\pixellib\semantic__init__.py in
2 import numpy as np
3 from PIL import Image
----> 4 from .deeplab import Deeplab_xcep_pascal
5 from .deeplab import Deeplab_xcep_ade20k
6 import cv2
~\anaconda3\lib\site-packages\pixellib\semantic\deeplab.py in
13 from tensorflow.python.keras.layers import Add
14 from tensorflow.python.keras.layers import Dropout
---> 15 from tensorflow.python.keras.layers import BatchNormalization
16 from tensorflow.python.keras.layers import Conv2D
17 from tensorflow.python.keras.layers import DepthwiseConv2D
ImportError: cannot import name 'BatchNormalization' from 'tensorflow.python.keras.layers' (C:\Users\GIRISH MAURYA\anaconda3\lib\site-packages\tensorflow\python\keras\layers__init__.py)
I am getting below error after executing the above command
import pixellib from pixellib.tune_bg import alter_bg
ImportError Traceback (most recent call last) C:\Users\GIRISH~1\AppData\Local\Temp/ipykernel_14768/2708208855.py in
1 import pixellib
----> 2 from pixellib.tune_bg import alter_bg
~\anaconda3\lib\site-packages\pixellib\tune_bg__init__.py in
2 import numpy as np
3 from PIL import Image
----> 4 from pixellib.semantic.deeplab import Deeplab_xcep_pascal
5 from pixellib.semantic import obtain_segmentation
6 import cv2
~\anaconda3\lib\site-packages\pixellib\semantic__init__.py in
2 import numpy as np
3 from PIL import Image
----> 4 from .deeplab import Deeplab_xcep_pascal
5 from .deeplab import Deeplab_xcep_ade20k
6 import cv2
~\anaconda3\lib\site-packages\pixellib\semantic\deeplab.py in
13 from tensorflow.python.keras.layers import Add
14 from tensorflow.python.keras.layers import Dropout
---> 15 from tensorflow.python.keras.layers import BatchNormalization
16 from tensorflow.python.keras.layers import Conv2D
17 from tensorflow.python.keras.layers import DepthwiseConv2D
ImportError: cannot import name 'BatchNormalization' from 'tensorflow.python.keras.layers' (C:\Users\GIRISH MAURYA\anaconda3\lib\site-packages\tensorflow\python\keras\layers__init__.py)