# Import library to Python3 function node

**URL:** <https://discourse.nodered.org/t/import-library-to-python3-function-node/16528>\
**Category:** General\
**Created:** [10 October 2019 04:39 UTC](https://discourse.nodered.org/t/import-library-to-python3-function-node/16528 "2019-10-10T04:39:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anguslou](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/anguslou/32/9212_2.png) [@anguslou](https://discourse.nodered.org/u/anguslou)\
**Post date:** [10 October 2019 04:39 UTC](https://discourse.nodered.org/t/import-library-to-python3-function-node/16528/1 "2019-10-10T04:39:27Z")

</div>

Hi,

I have a python3 function node that needs to import python library like pytorch, I tried but seems cannot import library just like other python compilers. Any idea?

Angus

---

<div class="post-metadata">

**Author:** ![bakman2](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bakman2/32/6207_2.png) [@bakman2](https://discourse.nodered.org/u/bakman2)\
**Post date:** [10 October 2019 05:32 UTC](https://discourse.nodered.org/t/import-library-to-python3-function-node/16528/2 "2019-10-10T05:32:46Z")

</div>

Perhaps you can try to use the [suggestion described in the open issues for that node](https://github.com/arnauorriols/node-red-contrib-python-function/issues/3).  
You may be better off running your python code via an exec node instead.
