# Sklearn: cannot allocate memory in static TLS block

**URL:** <https://forums.developer.nvidia.com/t/sklearn-cannot-allocate-memory-in-static-tls-block/210791>\
**Category:** Jetson Nano\
**Tags:** jetson-inference\
**Created:** [April 10, 2022, 8:10pm UTC](https://forums.developer.nvidia.com/t/sklearn-cannot-allocate-memory-in-static-tls-block/210791 "2022-04-10T20:10:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tun69093](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@tun69093](https://forums.developer.nvidia.com/u/tun69093)\
**Post date:** [April 10, 2022, 8:10pm UTC](https://forums.developer.nvidia.com/t/sklearn-cannot-allocate-memory-in-static-tls-block/210791/1 "2022-04-10T20:10:09Z")

</div>

I installed Sklearn by the command `pip3 install scikit-learn`

 ![image](https://global.discourse-cdn.com/nvidia/original/3X/7/1/7143f8c8bbacbf2dd5b4810e555c3432a15e93fd.png)

After installation, I could not import sklearn.

 ![image](https://global.discourse-cdn.com/nvidia/original/3X/6/7/67699b2ec5d3edf39c2bb07c69ba0571c1a88c7f.png)

Even though I tried

```auto
$ source ~/.bashrc
$ export LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libgomp.so.1

```

It did not work and get the same error.  
 ![image](https://global.discourse-cdn.com/nvidia/original/3X/a/3/a3bccc7ee97c424d691daae77fcc896f300b471d.png)  
`Python 3.6.9`

---

<div class="post-metadata">

**Author:** ![AastaLLL](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/aastalll/32/14043_2.png) [@AastaLLL](https://forums.developer.nvidia.com/u/AastaLLL)\
**Post date:** [April 11, 2022, 4:43am UTC](https://forums.developer.nvidia.com/t/sklearn-cannot-allocate-memory-in-static-tls-block/210791/3 "2022-04-11T04:43:41Z")

</div>

Hi,

I can import sklearn without errors.  
Below is our library version for your reference.

- numpy: 1.18.0
- scipy: 1.1.0
- sklearn: 0.24.2

Thanks.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/system/32/68080_2.png) [@system](https://forums.developer.nvidia.com/u/system)\
**Post date:** [May 4, 2022, 5:32am UTC](https://forums.developer.nvidia.com/t/sklearn-cannot-allocate-memory-in-static-tls-block/210791/5 "2022-05-04T05:32:57Z")

</div>

Closed on May 4, 2022, 5:32am UTC

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
