Question on scripting

anirban

Member
Is there a programmatic way to close a ProcessInstance?

Code:
var P = ProcessInstance.fromIcon("Process01");
P.launch();
P.executeOn(w[0].currentView);

I want close the ProcessInstance P programmatically.

Can anyone help?
 
This functionality is not available. Once you open an interface window, only the user can close it.

However, why are you launching the instance (which forces its interface to be shown)? This is not necessary to execute a process instance. In other words, unless you have a very good reason to open the interface window, you can simply delete the second line in your code snippet.
 
I was using this for DBE. I didn't find a good way of adjusting sample weights across images without launching the interface.
 
Just to understand the context: changing the points programmatically is not the big question I guess, the real question is why you would a script to place the points on your behalf? DBE is a process that highly requires the user to inspect the data to accurately place the control points in order to address issues that are mostly recognized visually or performing punctual measurements on the data. I can hardly immagine a script that could do this job on behalf of you...
 
By the way, I guess modifying programmatically the DB points programmatically is not straightforward, looking at the source code transported by the DB Icon I see a lot of parameters associated with the points calculated and stored by the process, so changing a point programmatically would require adjusting those parameters accordingly...
 
i think that in some instances a script which could do initial placement of samples while avoiding stars under the guidance of an astrometric solution would be awesome.
 
A really nice idea. Thank you for this excellent suggestion. Since we are going to write a new process for background modeling, this is definitely in the list of new features.
 
Back
Top