Call Python Script from C++

I am creating Paraview’s custom application in C++. How can I execute python script from my C++ code.
In my python script I am selecting points based on ID

See uses of vtkPythonInterpreter class in ParaView/VTK code. For example, vtkPythonAnimationCue is a C++ animation component that executes Python code to do processing in Python at each animation step.


Thank you, I tried following the example but seems like there is an issue with my project setup or the way I am calling python

C:\Users\msaad\AppData\Local\Programs\Python\Python311\include\object.h(239,23): error C2059: syntax error: ';' [C:\Users\msaad\M3SIMGui\build\client\m3sim_gui.vcx
C:\Users\msaad\AppData\Local\Programs\Python\Python311\include\object.h(239,23): error C2238: unexpected token(s) preceding ';' [C:\Users\msaad\M3SIMGui\build\clie

Not entire sure what could be the issue without looking at the code. One thing that comes to mind is make sure vtkPython.h is the first file included in the .cxx file, eg.