neo-ai / neo-ai-dlr

Neo-AI-DLR is a common runtime for machine learning models compiled by AWS SageMaker Neo, TVM, or TreeLite.
Apache License 2.0
491 stars 107 forks source link

Amazon Linux - version `GLIBC_2.27' not found #277

Open saranyailla opened 3 years ago

saranyailla commented 3 years ago

Hi, Pre-trained image classification models that are compiled using SageMaker-Neo DLR work just fine but the object detection models; for eg. yolo3 and ssd512 when compiled and run on Amazon linux instance errors out as below

  File "/home/ec2-user/.local/lib/python3.6/site-packages/dlr/dlr_model.py", line 185, in _check_call
    raise DLRError(self._lib.DLRGetLastError().decode('ascii'))
dlr.dlr_model.DLRError: TVMError: Check failed: lib_handle_ != nullptr: Failed to load dynamic shared library /home/ec2-user/ssd/compiled.so /lib64/libm.so.6: version `GLIBC_2.27' not found (required by /home/ec2-user/ssd/compiled.so)

The behavior is same for python3.6/3.7, dlr 1.0 - 1.3.0 and any amazon linux 2 instance as AL2 comes with GLIBC2.26 and these compiled models cannot find GLIBC2.27.

Both image classification and object detection models are from gluoncv model zoo and are compiled from AWS Sagemaker console for the platform linux - x86_64

trevor-m commented 3 years ago

Hi @saranyailla We are aware of this issue. Neo compiled models require GLIBC >= 2.27. We are working on a new compilation target setting which will allow compiled models to run on AL2012 and AL2.

In the meantime, is it possible for you to use Ubuntu 18.04 instead of Amazon Linux?

dougkelly commented 2 years ago

Any updates here on SM Neo models to run AL2?

Running any of the supporting image classification stack e.g. numpy on Ubuntu 18.04 (Cloud9) instance introduced a different set of dependency issues.