Hi there fellas,
I am struggling with the use of Python Nodes: the in- and output to be precise.
So far I have embedded it correctly and I can run python code in it. However, the in-and output in this case are files, which are read via hard code with a path, because I can’t figure out the input and output table in the python node.
My goal is to process data consisting of 3 columns and feed them into the Python Node, do some processing and generate one extra column, then have all 4 columns as output so that I can process the data in different nodes.
Tipps and tricks will be much appreciated!
It would help if you provided your workflow and sample data so that we can see what you’re working with and how the nodes are configured.
Understandable, but I really am interested into understanding the intput_table and output_table. Here is a basic workflow, where I have 3 columns mapped to the input_table and now I am not sure on how to print out a newly created column and the 3 from the start.
Thank you for your time.
BasicPythonAction.knwf (7.3 KB)
@nooby you can just use the input_table and output_table with the standard nodes. This will be Pandas data frames you will have to create within your Python environment.
But you are free to Im- and Export other data like Parquet, Pickle or NPZ or PNG directly within from within your code.
If you replace the last line of your code with:
output_table = df
then you’ll get the output you desire.
Thanks for the help, you two. Much appreciated.
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.