How to launch Glue from PyCharm in parallel

2 views
Skip to first unread message

Phil Edwards

unread,
Oct 20, 2019, 6:16:22 AM10/20/19
to Glue users
Hi,
   Is there a way of launching Glue from a Python program (in PyCharm) without blocking Python from executing the rest of the program?  If I use qglue, it launches Glue fine, but Python doesn't move on to the following line of code until I close Glue.  I tried adding the line %giu qt, but PyCharm gives an "invalid syntax" error.

   Also I want to just launch Glue but without passing it any data, since I want to open a previously saved session, using an updated data file.  qglue seems to require a dataset to be passed to it.  

   So, to conclude, is it possible to:
  1. Launch Glue from Python (PyCharm IDE) without stopping Python from continuing execution
  2. Launch Glue with no dataset passed to it
  3. Automatically have Glue "Open Session" on startup
  4. Have "Open Session" automatically open a particular session file that I specify in Python
Thanks
Phil

Thomas Robitaille

unread,
Feb 9, 2020, 11:14:34 AM2/9/20
to glue...@googlegroups.com
Hi Phil,

On Sun, 20 Oct 2019 at 11:16, Phil Edwards <phed...@gmail.com> wrote:
Hi,
   Is there a way of launching Glue from a Python program (in PyCharm) without blocking Python from executing the rest of the program?  If I use qglue, it launches Glue fine, but Python doesn't move on to the following line of code until I close Glue.  I tried adding the line %giu qt, but PyCharm gives an "invalid syntax" error.

The magic command should be %gui qt (not %giu qt) - does it them work if you try this? 

   Also I want to just launch Glue but without passing it any data, since I want to open a previously saved session, using an updated data file.  qglue seems to require a dataset to be passed to it.  

   So, to conclude, is it possible to:
  1. Launch Glue from Python (PyCharm IDE) without stopping Python from continuing execution
I think it should work with %gui qt but let me know if not 
  1. Launch Glue with no dataset passed to it
In theory running qglue() should work - does it not currently work for you? 
  1. Automatically have Glue "Open Session" on startup
See my reply to your other thread - using GlueApplication.restore_session should work. 
  1. Have "Open Session" automatically open a particular session file that I specify in Python
So do you mean that you want to make it so that when you open a session from the GUI, the default suggested file is a specific one? I don't think this is possible at the moment.

Cheers,
Tom
 
Thanks
Phil

--
You received this message because you are subscribed to the Google Groups "Glue users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to glue-viz+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/glue-viz/61e87d33-7d95-4d75-8557-041366928c2d%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages