Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PyTorch not working in JupyterLab #34

Open
YaBr11 opened this issue Mar 27, 2021 · 1 comment
Open

PyTorch not working in JupyterLab #34

YaBr11 opened this issue Mar 27, 2021 · 1 comment

Comments

@YaBr11
Copy link

YaBr11 commented Mar 27, 2021

Hi everyone,

I tried the new Jetcard Image based on Jetpack 4.5.1 on my Jetson Nano A02.
But as soon as I try to import torch or torchvision in a Jupyter Notebook I get the following error:
OSError: /usr/lib/aarch64-linux-gnu/libgomp.so.1: cannot allocate memory in static TLS block

Importing torch in terminal using the python3 environment works fine.
Any ideas what's the cause for that?
Thank you

@baixianger
Copy link

here is the easy way to solve your problem:
add a new path to the ~/.bashrc, then source it.

sudo vim ~/.bashrc
#add the line I mentioned below
source ~/.bashrc
export LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libgomp.so.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants