# RDKit functionality rom Python Script failed

**URL:** <https://forum.knime.com/t/rdkit-functionality-rom-python-script-failed/5572>\
**Category:** Community Extensions\
**Tags:** rdkit\
**Created:** [January 11, 2017, 4:41pm UTC](https://forum.knime.com/t/rdkit-functionality-rom-python-script-failed/5572 "2017-01-11T16:41:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aziza](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/a/e47774/32.png) [@aziza](https://forum.knime.com/u/aziza)\
**Post date:** [January 11, 2017, 4:41pm UTC](https://forum.knime.com/t/rdkit-functionality-rom-python-script-failed/5572/1 "2017-01-11T16:41:26Z")

</div>

Hi all,

I am trying to use RDKit functionality from a Python Script node. I am gettig an error message: 'ImportError: DLL load failed: The specified module could not be found.'

I am using Knime verison 2.12.2. I installed Anaconda (to Z:\PythonAnaconda\pywin27) following the instructions provided on [https://www.knime.org/blog/how-to-setup-the-python-extension.](https://forum.knime.com/blog/how-to-setup-the-python-extension) Environment variables are set as follows:

RDBASE = Z:\PythonAnaconda\pywin27

PYTHONPATH = %RDBASE%

PATH = ; %RDBASE%\lib

To test the installation I used a Python Script node with the following code:

```
# imports 
from rdkit import Chem
import numpy
from pandas import DataFrame
 
output_table = DataFrame(input_table['BMS'])
output_table['Copy_BMS'] = input_table['BMS']
```

In the node window a message appears: 'Starting python...' and then 'Successfully loaded input data into python'.

Executing the script resulted in this error message:

Traceback (most recent call last):  
&nbsp; File "C:\Program Files\KNIME\_2.11.2\plugins\org.knime.python\_2.12.0.0047785\py\PythonKernel.py", line 282, in execute  
&nbsp;&nbsp;&nbsp; exec(source\_code, \_exec\_env, \_exec\_env)  
&nbsp; File "\<string\>", line 2, in \<module\>  
&nbsp; File "Z:\PythonAnaconda\pywin27\lib\site-packages\rdkit\Chem\_\_init\_\_.py", line 18, in \<module\>  
&nbsp;&nbsp;&nbsp; from rdkit import rdBase  
ImportError: DLL load failed: The specified module could not be found.

Any ideas how to solve this issue? Have I missed a step during the setup? Any help is highly appreciated :)

cheers

aziza

&nbsp;

&nbsp;

&nbsp;

- 
-

---

<div class="post-metadata">

**Author:** ![greglandrum](https://forum-cdn.knime.com/user_avatar/forum.knime.com/greglandrum/32/680_2.png) [@greglandrum](https://forum.knime.com/u/greglandrum)\
**Post date:** [January 11, 2017, 8:37pm UTC](https://forum.knime.com/t/rdkit-functionality-rom-python-script-failed/5572/2 "2017-01-11T20:37:22Z")

</div>

Hi Aziza,

Assuming that you installed the RDKit in your anaconda environment using conda install -c rdkit rdkit (which I would strongly suggest), then I'd suggest getting rid of the changes that you made to your environment (you don't need the RDBASE variable or changes to PYTHONPATH or PATH).

-greg

---

<div class="post-metadata">

**Author:** ![system](https://forum-cdn.knime.com/uploads/default/original/1X/ab3ccf34482a0329361734a18199390177204f15.png) [@system](https://forum.knime.com/u/system)\
**Post date:** [April 21, 2023, 9:10pm UTC](https://forum.knime.com/t/rdkit-functionality-rom-python-script-failed/5572/3 "2023-04-21T21:10:20Z")

</div>

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