Presentation is loading. Please wait.

Presentation is loading. Please wait.

UI & Interfaces : latest updates

Similar presentations


Presentation on theme: "UI & Interfaces : latest updates"— Presentation transcript:

1 UI & Interfaces : latest updates
Koichi Murakami KEK/CRC

2 Outlook Qt UI commands G4UIExective MPI interface Python Interface

3 Qt Stable on Linux / Qt4 Prescription for Mac configuration
Qt3 support will be dropped. SL4 (RH ES4) is affected.

4 Range check for UI commands
improve range check for UI commands with default unit G4UIcmdWithADoubleAndUnit G4UIcmdWith3VectorAndUnit Default unit should be set For example, /xxxx/setLength 1 m 0 < x < 10 (cm) Range Error !

5 /control/ commands New stuff Usage:
/control/if <alias> “< <= > >= == !=“ <macro> /control/add <alias> <value1> <value2> /control/subtract <alias> <value1> <value2> /control/multiply <alias> <value1> <value2> /control/divide <alias> <value1> <value2> Usage: control/if {alias_name} > 1 macro.mac If “alias_name” > 1, then execute “macro.mac”

6 G4UIExecutive G4UIExecutive is available in 9.3 release.
convenient class for selecting a UI session according to environment variables, G4UI_USE_XXX. QT, XM, WIN32, TCSH, UIterminal (fallback) select a session type by the order above Pros: just one line cares the selection of a session type Cons: Environment variables might cause unexpected behaviors. G4UIExective is used in all examples. an aspect of code review for examples

7 G4UIExecutive in main()
In your main(), #include “G4UIExecutve.hh” if (argc != 1) { // batch mode G4String fileName = argv[1]; UImanager-> ApplyCommand(“/control/execute ” + fileName); } else { // interactive mode G4UIExecutive* ui = new G4UIExecutive(argc, argv); if (ui-> IsGUI()) ; // say something ui-> SessionStart(); delete ui; }

8 MPI interface Code reviewed OpenMPI as default instead of LAM/MPI
LAM/MPI is becoming obsolete … Developers shift to OpenMPI does not work on recent distributions improve macro file parser same parser as G4UIbatch Improve /mpi/status command clock counting with checking kernel status changed "beamOn" behavior for better performance fixed unexpected behavior at the end of batch mode

9 Python interface Now Ready for Python 3
Boost-Python is ready for Python3 Some distributions include Python3 Python 3 is not backward compatible Python2 script cannot run on Python3 Codes for both Python2 and Python3 should be provided. Experimental support for Python3 on December release.

10 New example of GTK application
EM Calculator pyGTK is used. Show stopping power for e/mu/proton and cross section for gamma Select a particle and select/set a NIST material Show stopping power / cross sections on ROOT graph and text data

11 Summary Qt interface UI comands G4UIExective MPI interface
stable on Linux prescription for Mac configuration drop Qt3 support UI comands improve range check new control stuff G4UIExective uniform way of UI session MPI interface code reviewed for better performance Python interface ready for Python3 example of GTK application

12 Thanks


Download ppt "UI & Interfaces : latest updates"

Similar presentations


Ads by Google