Possible for Python(& R) to signal progress to Knime?

I have some long running Python scripts, currently they run at 30% until finished.

I was wondering if it is possible to signal progress to Knime, through some exposed object or watched variable?

I would love to do the same with R

Hi @insightminer,

There is currently no functionality for that in the Python nodes, unfortunately. I have opened a feature request and will let you know once this has been worked on. (I think this is also true for R and have included R in the feature request, too – but I rarely use R myself, so maybe there is some way.)

Marcel

3 Likes

@insightminer depending on your script you could construct some sort of pseudo progress tracker. If you have steps in your script at certain points you could tell the R or Python script to write a small TXT file with a timestamp to disk. This could either be one single file where you would record the time and maybe the step in your program or just a timestamp so you could see some progress or simple Ping (indicating the program is still ‘alive’).

This obviously is only a workaround and if you have single steps in the program that would take some time there might not be much progress.

From what understand about the progress indicator of R and Python snippets they just indicate the number of lines that have been executed - maybe reserving some portion for setup and final transfer but not ‘real’ progress. So a simple print might have the same % of progress that a large file operation.

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