JAIDA, AIDA-JNI, JAS3 Status and Plans Mark Dönszelmann, Tony Johnson, Joseph Perl, Victor Serbo, Max Turri AIDA Workshop CERN July 2003

Download Report

Transcript JAIDA, AIDA-JNI, JAS3 Status and Plans Mark Dönszelmann, Tony Johnson, Joseph Perl, Victor Serbo, Max Turri AIDA Workshop CERN July 2003

JAIDA, AIDA-JNI, JAS3
Status and Plans
Mark Dönszelmann, Tony Johnson, Joseph Perl,
Victor Serbo, Max Turri
AIDA Workshop
CERN July 2003
Contents
 JAIDA – Java Implementation of AIDA
 Part of FreeHEP Java library
 AIDA-JNI – C++ interface to JAIDA
 JAS3 – Experiment, Data Format independent graphical
data analysis tool based on JAIDA
JAIDA, AIDA-JNI, JAS3
July 2003
JAIDA
 JAIDA = Java implementation of AIDA
 Complete implementation of AIDA interfaces
With a few exceptions
– limited support for plot styles currently
– Some missing features in ITree, cp, mv
 Uses Java “service provider mechanism” for dynamic loading of
services at Runtime
Can be used to add support for new fitters, stores etc.
Have defined “developer level” interfaces for IOptimizer, IStore etc
 Uses Java Expression Library (JEL) for runtime compilation of
expressions (for tuple evaluators and functions)
JAIDA, AIDA-JNI, JAS3
July 2003
JAIDA – Features continued…
 Fitting




support for multiple fitting engines (optimizers)


Support for multiple fitting methods

Stores







LeastSquares, Chi2, CleverChi2, BinnedMaximumLikelihood and UnbinnedMaximumLikelihood
Read/Write support for AIDA XML format (with built-in gzip)
Read support for HBOOK/PAW files (needs hbookAdapter native library)
Read support for Root files (write support hopefully coming soon)
Future plans to add:

Plotting

UNCMIN (pure Java)
Minuit (needs minuitAdapter native library)
SQL interface, JDO interface, text file support …
Two implementations of IAnalysisFactory


BatchAnalysisFactory – dummy plotter, ignore calls to IPlotter
AnalysisFactory – Full plotter functionality
–
limited user input, for full GUI use JAS3
Multi-Threaded – plots update in real-time as they are filled

No need to call interact() or refresh()
Support for embedding plotter


In other Java GUI’s
In Java servlets for web based applications.
Graphics export in many formats including:

PDF, EPS, SVG, SWF, PNG, GIF, JPG
JAIDA, AIDA-JNI, JAS3
July 2003
Using JAIDA with Java
JAIDA, AIDA-JNI, JAS3
July 2003
Using JAIDA with Python
JAIDA, AIDA-JNI, JAS3
July 2003
Using JAIDA with C++
JAIDA, AIDA-JNI, JAS3
July 2003
AIDA-JNI
 C++ interface uses AIDA-JNI
AIDA- JNI
AIDA
AIDA
C++ program
JAIDA
 AIDA-JNI partially generated by AID, partly by hand
 Does not currently support full AIDA functionality
 AID improvements (v 0.9.5) coming soon
 JNI Adapters generated to interface with JACE generated code
JACE (JNI made easy) version 1.1 code generates connector to allow
access from C++ to Java
AID generates code to implement the AID interfaces using the JACE
generated code
JAIDA, AIDA-JNI, JAS3
July 2003
Future Plans for JAIDA
 Complete implementation of missing features
 Continue to track improvements to AIDA standard
 Add support for function arithmetic
 Web Interface (see later talk)
 Support for “Remote AIDA” (see later talk)
 Support for more storage formats
 Need good binary IO format .. either AIDA standard or roll our own
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 Overview
 A completely new version of JAS
 Design based on Application Shell, into which many (optional)
modules can be plugged
Highly customizable for different application domains
– HEP/Astrophysics/Other
– DST analysis/Online Monitoring/GRID analysis
– Experiment/User specific modules
Modules can be updated independently of shell
– Possible to release bug fixes fast
 Includes support for programming in many languages
Scripting: Python, Pnuts, Dynamic Java, ….
– Command prompt
Java (compiled)
 Analysis (histograms, tuples, fitting) based on AIDA standard
 Not technically backwards compatible with JAS2
 But migration is straightforward.
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 and AIDA
 JAS3 supports all AIDA functionality, including
 Histograms (includes arithmetic, projections, etc.)
 Clouds (unbinned histograms, scatterplots)
 Plotter
 Tuples
 Fitting – AIDA interfaces allow for multiple fitters
Uncmin -- pure java minimizer
Minuit -- Fortran called by Java Native Interface (JNI)
 IO
AIDA XML, PAW, Root
 JAS3 supports user interaction with AIDA in three ways
 Scripting (Pnuts, Python etc)
 Compiled (Java) code
 GUI – Plotting, Fitting, Cuts etc.
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 Scripting
 JAS3 has multi-language OO scripting support
 Command line, Console, Editor
 Major components (e.g. AIDA) have scripting interfaces
 Currently have plugins to support
 Pnuts – syntax almost identical to Java, fast, well documented
and feature complete
 Python (using Jython)
 More scripting languages can be added
not restricted to Java implementations (e.g. could use C-Python, JPE)
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 Lightning Tour
 Tour designed to
give you an
overview of the
capabilities of JAS3,
you can try them
out for yourself this
afternoon.
Welcome Page, gives initial
info and links to example
scripts and programs
JAIDA, AIDA-JNI, JAS3
Memory
monitor
July 2003
Opening Files
Use file
menu
Drag from
explorer
JAIDA, AIDA-JNI, JAS3
July 2003
Graphical Interface to AIDA
Histograms,
Clouds, Tuples
all presented in
AIDA tree
.aida files,
.hbook files,
.root files all
presented as
AIDA objects
JAIDA, AIDA-JNI, JAS3
July 2003
Drag items onto
page, or use
(popup) menus
Printing
Or
copy/paste
into Word,
PowerPoint
etc.
Can send
individual
plots or full
page
direct to
printer
JAIDA, AIDA-JNI, JAS3
Or save as PS,
EPS, PDF, SWF,
SVG, PNG, GIF…
July 2003
Java Editor, Compiler and Loader
Tree
shows
loaded
programs
Built-in Java
compiler
JAIDA, AIDA-JNI, JAS3
Built-in
editor for
writing
analysis
code
Unlike JAS2 which only supported “event
analyzers” JAS3 allows any Java program
to be loaded.
This example “main routine” is
July 2003
taken directly from the AIDA manual
Scripting
Can also
write and run
scripts
Console allows
direct interaction
with scripting
language
JAIDA, AIDA-JNI, JAS3
July 2003
Pnuts Language
 Currently favour Pnuts scripting language
 Complete and well documented
http://javacenter.sun.co.jp/pnuts/doc/guide.html
 Fast (although not as fast as compiled Java)
 Syntax very similar to Java
 Can easily call compiled Java classes from scripts – best of both
worlds
JAIDA, AIDA-JNI, JAS3
July 2003
Record Sources
Opening record
(or event)
based files
causes the run
control toolbar
to appear
JAIDA, AIDA-JNI, JAS3
Works similarly to JAS2
Job control, but now also
supports random access
and “tagged” data sets
(mainly for event
displays)
July 2003
Tuple Explorer - Plots
Histogram
Works with any tuple,
read from file or
dynamically created
ScatterPlot
XY Data
(More appropriate for
smaller data sets)
JAIDA, AIDA-JNI, JAS3
July 2003
Profile
Tuple Explorer – Define Columns
JAIDA, AIDA-JNI, JAS3
July 2003
Tuple Explorer - Cuts
JAIDA, AIDA-JNI, JAS3
July 2003
Tuple Explorer - Tabulate
JAIDA, AIDA-JNI, JAS3
July 2003
Tuple Explorer – Record Source
To be used with record loop
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 Spreadsheet
 Simple spreadsheet plugin
 for
 Displaying results
 Calculations
 Simple Plots
 Supports reading/writing
 .csv files
 Excel files
 Cut/Paste with Excel etc
 Coming Soon…
 Scripting interface
 GUI for building plots
 User defined functions
– Java, scripting
JAIDA, AIDA-JNI, JAS3
July 2003
Miscellaneous Features
Save/Restore
configuration
User
Preferences
Plugin
Manager
JAIDA, AIDA-JNI, JAS3
July 2003
Status
 Currently released JAS3 version 0.7.1
 AIDA functionality is quite solid
 Compiler, Loader, Record Loop all quite recently added,
Certainly still some rough edges
 Documentation limited but available
 Built-in example scripts and programs
 Tutorial on web
 If you are used to JAS2 you will find some functionality
not yet ported to JAS3
 Remote (client/server) access to data.
 3D Lego/Surface plots
JAIDA, AIDA-JNI, JAS3
July 2003
JAS 2 – GRID interface (Tech-X)
JAIDA, AIDA-JNI, JAS3
July 2003
JAS and the GRID
 We plan to add client-server/distributed capabilities to
JAS3 similar (but better) than those in JAS2
 Will be based on (remote) AIDA
 Want to use Grid standards where they exist
Work with others (PPDG-CS11,???) to define standards where they
do not exist
 Want to be compatible with C++ servers
But don’t want to loose flexibility of dynamically loading analysis code
into server
 Tech-X have phase II SBIR approved and will work closely with us
JAIDA, AIDA-JNI, JAS3
July 2003
JAS3 Links, More Info
 JAS – Java Analysis Studio - http://jas.freehep.org
 JAS3 – http://jas.freehep.org/jas3
 JAIDA – http://java.freehep.org/jaida/
 AIDA – http://aida.freehep.org
 FreeHEP - http://www.freehep.org
 FreeHEP Java Libraries - http://java.freehep.org
 WIRED – http://wired.freehep.org
JAIDA, AIDA-JNI, JAS3
July 2003