Python Error in KNIME Example

Dear KNIME experts,

I am getting “ERROR Python Source 2:14 Execute failed: Could not start Python kernel. Error during Python installation test: Python installation could not be determined.The system cannot find the path specified.”

When I execute the ‘Python Source’ node in the example:

Examples: 50_Applications - 01_Stocks

• I can run other examples which need Python and I have it installed

For example I have no problem running the DL Python Network Editor

I am working on Windows 10 and have a further problem which is that I cannot install the ‘datetime’ package in Anaconda. It seems to be outdated.

Would appreciate any comments and suggestions.

Thanks,

Leon

Hi Leon,

Do you have different settings on the “Python” vs. the “Python Deep Learning” preference pages? You can check that via File > Preferences > KNIME and then Python and Python Deep Learning, respectively. This would explain why the deep learning nodes are working and the ordinary Python nodes are not. Or did you also successfully run other workflows that contain ordinary (i.e., not deep learning) Python nodes?

I believe you actually do not need datetime to run the workflow. At least it worked for me after only installing pandas-datareader in addition to the packages that are already required by the KNIME Python integration itself. Can you confirm this (once we got your Python nodes running of course :slightly_smiling_face:)? Then we can update the description of the example workflow.

Marcel

3 Likes

Anaconda and various repositories and package compatibility is still not so easy.

You have to sometimes go back and forth and sometimes install an additional package by pip and hope it integrates well with you system. Or you could mange different python environment besides “base”.

I compiled a small list of steps with regards to keras and KNIME. You would have to check if the versions required are still the same.

1 Like

Thanks Marcel,

You are 100% right. When I made the setting in the preferences, it worked well.
package ‘datatime’ was also not a problem anymore.

Many thanks for the help!
Leon

1 Like

Thanks mlauber71,

I got it working thanks. I would be interested to learn now I should use Anaconda to manage update the packages. If you have something written down I would much appreciate it,

Thanks,
Leon

Great! Glad to help :slight_smile:. Thanks for reporting the datetime issue. We will update the example workflow as soon as possible.

Marcel

1 Like

Bot that much actually. It boils down to this:

  • use Anaconda and be aware of different channels
  • mostly stick to one channel like the default “Anaconda”
  • be aware of channel priorities (which is not straightforward), stick to you original channel
  • let Anaconda do most of the management of dependencies
  • use “conda update anaconda” and “conda update conda”
  • if a package is not available you might use pip
  • if you Python installation becomes corrupt delete the whole thing and start over again

I have not yet integrated things like docker and a proper management of different environments into the fold.

1 Like

Thanks so much mlauder71,

Could you please comment on the difference between the two?

“conda update anaconda” and “conda update conda”

Thanks,
Leon

In general conda is the package manager and anaconda is the whole collection of Python packages. Some recommendations went to first update conda and then anaconda.

2 Likes

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