AttributeError: 'module' object has no attribute 'elementwise_mul'
Created by: gongweibao
When I run https://github.com/PaddlePaddle/models/blob/develop/fluid/image_classification/se_resnext.py, I met an error:
Traceback (most recent call last):
File "se_resnext.py", line 160, in <module>
train(learning_rate=0.1, batch_size=8, num_passes=100)
File "se_resnext.py", line 110, in train
out = SE_ResNeXt(input=image, class_dim=class_dim)
File "se_resnext.py", line 91, in SE_ResNeXt
reduction_ratio=reduction_ratio)
File "se_resnext.py", line 62, in bottleneck_block
reduction_ratio=reduction_ratio)
File "se_resnext.py", line 31, in squeeze_excitation
scale = fluid.layers.elementwise_mul(x=input, y=excitation, axis=0)
AttributeError: 'module' object has no attribute 'elementwise_mul'
The PaddlePaddle is installed by pip install paddlepaddle
and the version is 0.11.
It seems that it needs a new PaddlePaddle version.
Since models
are used for end users, maybe we need to test our implement from the user's point of view.