SARIMA Uploaded with errors - on K.AP 5.1.1 (but on 4.7.7 it works... why?)

Good morning everybody.

attached (SARIMA learner node and some troubles about some packages impossibile to install).
As you can see this is a list of issues I’m facing since some days ago:

  • error uploading SARIMA Learner Component;
  • conflicts about Pythoun Script (datetime import from pandas)
  • unable to install on conda eviroment “base” the package tensorflow - mkl (any version)

The most incomprehensible thing is that on another PC (a company PC) where I installed a previous version of KNIME (KNIME Analytics Platform version 4.7.7), I did not encounter any problems executing workflowss with the SARIMA Learner component.

Do you think it’s a problem due to the KNIME installation? Or Conda installation?
When installing some package on the environment?
I’ll tell you that I tried to uninstall conda including deleting all the environments and related installed packages and I tried reinstalling everything from scratch including KNIME, but I still encounter the same problems.

Thank you in advance for any support you can provide me.
Best regards
Pierpaolo



image 3

Hello @PVergati,

In the last snapshot, if you select the Bundled environment then errors related to SARIMA Learner will go away. This is because, selecting “Bundled” option will tell the component to use the dependencies that are shipped with KNIME.

For the tensorflow configuration, I would recommend you to create a seperate conda environment, or use the option below the current selected option (second last image). It should work for you.

Thank you

Best,
Ali

1 Like

Dear Mr. Aliasghar

first of all thanks for you support.
I tried the first advice and I’ve switched to Bundled Enviroment for Python.
Unfortunately i’ve encountered another surprising issue. I’ll post the console error message…
I wonder if I’m the only one who has encountered this kind of problem before now.

I Hope you could recognize the problem

ERROR Python Script 5:420:0:374 Execute failed: ImportError: cannot import name ‘datetime’ from ‘pandas’ (C:\Users\maidi\anaconda3\Lib\site-packages\pandas_init_.py)
WARN Python Script 5:420:0:374 :3: FutureWarning: The pandas.datetime class is deprecated and will be removed from pandas in a future version. Import from datetime module instead.
WARN Python Script 5:420:0:374 C:\Program Files (x86)\KNIME\plugins\org.knime.pythonscripting.channel.v1.bin.win32.x86_64_5.1.0.v202303171438\env\lib\site-packages\statsmodels\tsa\base\tsa_model.py:471: ValueWarning: An unsupported index was provided and will be ignored when e.g. forecasting.
WARN Python Script 5:420:0:374 C:\Program Files (x86)\KNIME\plugins\org.knime.pythonscripting.channel.v1.bin.win32.x86_64_5.1.0.v202303171438\env\lib\site-packages\statsmodels\tsa\base\tsa_model.py:471: ValueWarning: An unsupported index was provided and will be ignored when e.g. forecasting.
WARN Python Script 5:420:0:374 C:\Program Files (x86)\KNIME\plugins\org.knime.pythonscripting.channel.v1.bin.win32.x86_64_5.1.0.v202303171438\env\lib\site-packages\statsmodels\base\optimizer.py:17: FutureWarning: Keyword arguments have been passed to the optimizer that have no effect. The list of allowed keyword arguments for method lbfgs is: m, pgtol, factr, maxfun, epsilon, approx_grad, bounds, loglike_and_score. The list of unsupported keyword arguments passed include: max_iter. After release 0.14, this will raise.
ERROR Python Script 5:420:0:374 Execute failed: KeyError: ‘Invalid port index 0, only 0 output_objects are available’

Dear @PVergati,

thanks for trying the bundled environment and for the additional details.
Could you please

  • send us a screenshot of the component showing the failing Python Script node?
  • send us a minimal example workflow or the link to the component on hub.knime.com?
  • try in Preferences -> KNIME -> Python to Create New Environment.. and use that one and try again?

Thanks
Steffen

Good Morning Steffen

thanks for your support.

here you can finde attached the screenshot showing the failing Python Script node inside the component.
The component is the Sarima Learner, available here

i’ll try with creating another enviroment (on Conda I think you meant) and try to reinstall all the needed component.

I’ll let you know if it can solve the issue
Thanks for you availability

Dear @PVergati,

thanks for the insights.

No, as I described, I would have liked you to try create a new environment via the preference page (see screenshot). Not on Conda.

But as I dug deeper, that is completely obsolete; the component is currently in a faulty state.
If you want to fix your local version, you can right-click on the component, then Component -> Disconnect link. This allows you to alter its content. Then please navigate to the failing Python Script node and delete the line from pandas import datetime. Save and execute. Does everything work then?

Best regards
Steffen

PS: Tagging @Corey : can we delete that line from pandas import datetime in the Python Script node with the subscription “SARIMA Learner” in the component on Hub? :slight_smile:

SARIMA_test.knwf (93.6 KB)
this test of mine runs through, does that run on you machine, too?

1 Like

Thanks Steffen!!! Now it Works!!!
Thank you a lot
PV

2 Likes

As a last remark: in your screenshot the line 30 might be wrong:
It should look like

knio.output_objects[0] = model_fit

But according to the right upper corner with the output variables it has knio.output_tables and not output_objects, so that might be faulty in your version, too.

Best regards
Steffen

1 Like

Hi Steffen, i think that a similar problem is now related to the SARIMA Predictor component.
Its execution seems to have similar problems in its execution.
I suppose that a similar resolution need to be applied.

Here I also suggest deleting ling 7 (from pandas import datetime) and (as the error indicates) change line 17 knio.input_objects to knio.input_tables

1 Like

Good afternoon Steffen, I follow the same thread only to alert you that I’ve tried to apply your suggestions on the SARIMA PREDICTOR COMPONENT but it seems to have other exceptions.
Inside the component there are 2 Python Script Nodes.
I’ve disconnnected the component link and then tried to apply your suggestions on the first Python script node and then to the second Python script node inside the Sarima Predictor Component.

Probably Corey could verify and then fix them.

You can find attached:

  • url of SARIMA PREDICTOR component
  • screenshot of 1st Python Script node inside the component with the errors during execution
  • screenshot of 2st Python Script node inside the component with the errors during execution



Thanks for the detailed follow-up!
@Corey could you have a look at the SARIMA Predictor component and the errors @PVergati gets? Thanks!

2 Likes

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