Correct way to update a vtkImageData and refresh the render window (renderWindow.Render() not working)

Thank you for the suggestion!

Though I tested running the MWE directly from windows powershell and it also has the same effect. The initial seconds or so work, then the window becomes unresponsive and stops updating.