Skip to content

_activation_ops.so: undefined symbol error when importing tensorflow_addons #753

Closed
@martin-gorner

Description

@martin-gorner

System information

  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Google Cloud AI Platform Notebooks, TF 2.0 image
  • TensorFlow version and how it was installed (source or binary): Google Cloud AI Platform Notebooks, TF 2.0 image
  • TensorFlow-Addons version and how it was installed (source or binary): 0.6.0, pip install
  • Python version: 3.5
  • Is GPU used? (yes/no): yes

Executing the following line in my notebook:
import tensorflow_addons as tfa
Generates the following error:
NotFoundError: /home/jupyter/.local/lib/python3.5/site-packages/tensorflow_addons/custom_ops/activations/_activation_ops.so: undefined symbol: _ZN10tensorflow12OpDefBuilder4AttrESs
Full error message:
NotFoundError Traceback (most recent call last)
in
5 from matplotlib import pyplot as plt
6 import PIL.Image, PIL.ImageFont, PIL.ImageDraw
----> 7 import tensorflow_addons as tfa
8 AUTOTUNE = tf.data.experimental.AUTOTUNE
9 print("Tensorflow version " + tf.version)

~/.local/lib/python3.5/site-packages/tensorflow_addons/init.py in
19
20 # Local project imports
---> 21 from tensorflow_addons import activations
22 from tensorflow_addons import callbacks
23 from tensorflow_addons import image

~/.local/lib/python3.5/site-packages/tensorflow_addons/activations/init.py in
19 from future import print_function
20
---> 21 from tensorflow_addons.activations.gelu import gelu
22 from tensorflow_addons.activations.hardshrink import hardshrink
23 from tensorflow_addons.activations.lisht import lisht

~/.local/lib/python3.5/site-packages/tensorflow_addons/activations/gelu.py in
23
24 _activation_ops_so = tf.load_op_library(
---> 25 get_path_to_datafile("custom_ops/activations/_activation_ops.so"))
26
27

/usr/local/lib/python3.5/dist-packages/tensorflow_core/python/framework/load_library.py in load_op_library(library_filename)
59 RuntimeError: when unable to load the library or get the python wrappers.
60 """
---> 61 lib_handle = py_tf.TF_LoadLibrary(library_filename)
62
63 op_list_str = py_tf.TF_GetOpList(lib_handle)

NotFoundError: /home/jupyter/.local/lib/python3.5/site-packages/tensorflow_addons/custom_ops/activations/_activation_ops.so: undefined symbol: _ZN10tensorflow12OpDefBuilder4AttrESs

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions