GDE - How it works


GDE calls programs that run as external jobs. In essence, any program can be run from GDE. Programs can run on a local server, or as a remote web service. Output is returned to the user's desktop in the appropriate viewer.



The GUI layer - GDE is the GUI layer. GDE is nothing more than a program that creates menus and calls other programs. Data selected in the GDE window is written to a temporary file. A Unix command generated by GDE that calls a program, using the temporary file as input, and supplying parameters as set in the menu. Output from the program is imported back into GDE, or sent to other programs for viewing by the user.

The Menu specification layer - When GDE starts, it reads a file called .GDEmenus. The .GDEmenus file contains specifications for each menu, and commands for running one or more programs. For example, in dGDE, the menu for Taxonomy --> Get DNA/Protein from TaxID looks like this:



The corresponding entry in the .GDEmenus file creates this menu:

#------------------- DNA/Protein From Organism List ( 4/10/06) --------------------------
item:Get DNA/Protein from TaxID
itemmethod: (python $BIRCH/script/flat2list.py in1 in1.nam; leash.listarray in1.nam in1.flat $WHATTOGET; rm in1 in1.nam; $WHERE)&
itemhelp:doc/dGDE/SeqHound_API_Functions.html#SHoundDNAFromTaxID
itemopen:browser.csh

in:in1
informat:flat
insave:

arg:WHATTOGET
argtype:chooser
arglabel:What to get
argchoice:DNA GI:dna.gi -mn SHoundDNAFromTaxID
argchoice:protein GI:pro.gi -mn SHoundProteinsFromTaxID
argvalue:0

arg:WHERE
arglabel:Send output to
argtype:chooser
argchoice:GDE:(dgde in1.flat; $RM_CMD -f in1*)&
argchoice:Output file:mv in1.flat $OUTFILE; echo ' Get DNA/Protein from TaxID completed'
argvalue:0

arg:OUTFILE
arglabel:Output file name
argtype:text

This menu sends a list of TaxID numbers to SeqHound, and returns a list of DNA or Protein GIs. The Unix command to accomplish this task is on the itemmethod: line. The command is build by substituting values from the other fields (eg. in1, WHATTOGET, WHERE, OUTFILE) into the itemmethod line. The itemmethod generates a series of commands. The first calls flat2list, a Python script that converts a GDE flat file into a raw list of names that can be used by leash. The script leash.listarray calls leash using the SeqHound method specified in WHATTOGET, using the GDE flat file as input. After removing some temporary files, the commands specified in WHERE send the output from leash either to a new GDE window, or to output files.

This aspect of GDE is what sets it apart from any other program of its kind. Because any program on the system can be called, there are few limits to what GDE can be asked to do. As well, the simplicity of the .GDEmenus file means that it is easy to add new programs to GDE, and that the cycle of testing and modification is far more rapid than would be required if it was necessary to re-compile GDE every time a program was added.

A complete description of syntax for .GDEmenus files is found in
GDE 2.2 Manual (PDF) .

The Command layer - The command built by GDE is executed by the Unix shell. If the command is run in the background (as shown in the example above) then it will run independently of GDE, which is especially important for long-running jobs. In fact, once the job has been started, the GDE window that launched it can be Quit, with no effect on the job. GDE can call anything that can be executed, either a binary, a Unix command, a script, anything that is executable. In a certain sense, GDE can do anything that a person can do at the command line.

The Computation layer -  Because the command(s) executed by GDE can include scripts, it is possible to launch scripts that orchestrate long computational pipelines involving many programs. There is not even any requirement that processing occur on the same machine that GDE is running on. In the example, GDE calls leash, a Java program that sends queries to the SeqHound data warehouse through the SeqHound API. As another example, the BLAST menus in the default BIRCH distribution call the NCBI blastcl3 client, which sends BLAST searches to NCBI.  At some BIRCH sites, BLAST searches are sent to GeneMatcher or Paracel servers. Except for the time required to get the results back, it is transparent to the user where the searches are run.



Next