What is "cannot allocate memory in static TLS block"

Hi, I’m encountering this problem when running live_demo.ipynb of trt_pose
Please help.
-----------error message --------------------------------------------
OSError Traceback (most recent call last)
in
1 import json
----> 2 import trt_pose.coco
3
4 with open(‘human_pose.json’, ‘r’) as f:
5 human_pose = json.load(f)

/usr/local/lib/python3.6/dist-packages/trt_pose-0.0.1-py3.6-linux-aarch64.egg/trt_pose/ init .py in
----> 1 import torch

~/.local/lib/python3.6/site-packages/torch/ init .py in
187 # See Note [Global dependencies]
188 if USE_GLOBAL_DEPS:
→ 189 _load_global_deps()
190 from torch._C import *
191

~/.local/lib/python3.6/site-packages/torch/ init .py in _load_global_deps()
140 lib_path = os.path.join(os.path.dirname(here), ‘lib’, lib_name)
141
→ 142 ctypes.CDLL(lib_path, mode=ctypes.RTLD_GLOBAL)
143
144

/usr/lib/python3.6/ctypes/ init .py in init (self, name, mode, handle, use_errno, use_last_error)
346
347 if handle is None:
→ 348 self._handle = _dlopen(self._name, mode)
349 else:
350 self._handle = handle

OSError: /usr/lib/aarch64-linux-gnu/libgomp.so.1: cannot allocate memory in static TLS block

Hi,

Could you try the the below command before launching the notebook?

$ export LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libgomp.so.1

Thanks.

3 Likes

Thanks! that works!

I have the same problem, but even doing this solution the error still happens.

Hi rafael3,

Please help to open a new topic with more details of your issue. Thanks