TRANSP to ElVis: elvislib - PowerPoint PPT Presentation

About This Presentation
Title:

TRANSP to ElVis: elvislib

Description:

ElVis was created with these programs in mind, which led to the creation of ... Tags contain information that is sent from elvislib to ElVis ... – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 28
Provided by: Mich872
Learn more at: https://w3.pppl.gov
Category:
Tags: elvis | transp | elvis | elvislib

less

Transcript and Presenter's Notes

Title: TRANSP to ElVis: elvislib


1
TRANSP to ElVis elvislib
By Ben BariteauMentor Doug McCune
2
Scientific Graphics
3
Data Monitoring Integrated with Job Monitoring
4
Web Services
5
ElVis Software Package
  • Display program
  • 45,000 lines of Java code
  • 300 classes
  • Summer 08 Over 200 updates to the code
  • Application Programming Interface (API)
  • Fortran
  • C/C
  • Java

6
TRANSP and elvislib
  • elvislib was created primarily for TRANSP so that
    the Fortran and C programs within TRANSP could
    take advantage of the Java visualization tool
    ElVis
  • elvislib is primarily used with programs like
    rplot, cstate, and sigtab for displaying graphs
    and tables with a GUI that allows for intuitive
    manipulation and management tools
  • ElVis was created with these programs in mind,
    which led to the creation of elvislib for these
    programs to send data to ElVis

7
elvislib EML Transfer
  • elvislib stores information in memory about
    different types of graphs, including normal two
    dimensional graphs, surface plots, indexed
    graphs, and tables
  • This information is translated into EML when
    ef_graphwindowdisplay() is called

8
Sending EML files
  • ef_sendfile() was created to send files to ElVis
    after they have been generated.
  • elvis_send_file uses ef_sendfile() to send files
    through the CLI
  • Changes in code
  • ef_sendfile() was created in graphwindow.c, which
    sends files to the destinations in the ElVis
    environment variable
  • Challenges
  • elvis_send_file had to remove all filenames from
    the ElVis environment variable, so that files
    could not be written to and read from
    simultaneously
  • ef_sendfile() had to be able to send concatenated
    EML, so that ElVis did not throw exceptions.

9
ElVis Markup Language (EML)?
  • EML is an XML-based language
  • Designed by Steve Krenzel
  • Tags contain information that is sent from
    elvislib to ElVis
  • elvislib creates these tags and ElVis translates
    these into graphs

10
EML DTD
11
Hierarchical EML Structure
  • All EML is contained within a tag
  • A graphwindow is contained within a
    tag
  • Graphs are contained within a tag

12
Tables
  • Tables can now be sent to ElVis
  • Changes in code
  • Column structure added
  • Column structure allows for an
  • array of strings
  • Columns have their own background
  • and font colors, as well as font style
  • (Italic, Bold) and a font (Serif,
    Monospaced, etc.)?
  • Column has a header that is the title of the
    column.

13
Tables, contd.
  • Changes in code
  • columnList added to Graph structure
  • A list of Columns contained in a Table graph.
  • topTextList and bottomTextList added to Graph
    structure
  • Lists of Labels that appear at the top and bottom
    of the Table, respectively.
  • Each label has it's own color, background color,
    font, and style attributes
  • Added EML output for Tables

14
Table Functions
  • Functions added to the API
  • concerning Tables
  • ef_tablecreate()?
  • ef_columncreate()?
  • ef_tableaddcolumn()?
  • ef_graphwindowaddtable()?
  • ef_columnsetrowlabels()?
  • ef_columnsetbgcolor()?
  • ef_columnsetheader()?
  • ef_columnsetfontname()?
  • ef_columnsetfontstyle()?
  • ef_columnsetfontsize()?
  • ef_columnsetfontcolor()?
  • ef_tableaddtoptext()?
  • ef_tableaddbottomtext()?

15
Tables and EML
  • Tables use multiple tags
  • Within each tag there can be a number of
    s
  • Each contains a value attribute
  • A can contain any of the attributes
    listed on the right
  • Tables can also have multiple and
    tags
  • These can contain the attributes listed on the
    right

16
Tables - Challenges
  • Creating a structure that could hold all the data
  • necessary and adding it to the current
    structures
  • Getting arrays of strings from Fortran to C
  • Defining the color mechanism (next section)?

17
Colors
  • Colors were used in
  • ef_graphaddlabel()
  • ef_tableaddtoptext()
  • ef_tableaddbottomtext()
  • ef_columnsetbgcolor()
  • ef_columnsetfontcolor()?
  • Previously, the API used 3 floating-point numbers
    from
  • 0.0 to 1.0 to represent colors
  • This made compatibility easy, but it was not
    intuitive
  • Now, the API takes a string with either a color
    value
  • (i.e. rgb 0.2 0.5 0.1) or color name
    (i.e. name blue)?
  • Future colorspaces like HSV can be added

18
Logarithmic Z Axis in Surface Plots
  • The index (Z) axis of this surface plot can now
  • be set to be logarithmic, unlike before,
    where
  • it could only be linear
  • Default linear on left, logarithmic on right
  • Used through ef_graphsetzaxis()?

19
Log Z-axis and EML
  • The z-axis logarithmic/linear scale control is
    sent through the tags
  • tags have a numberstyle attribute which
    controls the scale of a graph
  • This is interpreted through an with
    direction of z and a numberstyle of 4

20
Short Title
  • shortTitle in the tag
  • i.e.,
  • This allows for the a smaller title to be shown
    when the graph becomes too small to display the
    normal title
  • The top graph is large enough to show the entire
    title, while the bottom one is small enough to
    show a shortened smaller title

21
Short Title and EML
  • Short title was added to the EML through an
    attribute in the tag
  • now has an attribute called shortTitle,
    which specifies the short title
  • This is generated by elvislib when a shortTitle
    is specified

22
Gridlines
  • It is now possible to add gridlines to normal
  • graphs using ef_setxgrid and ef_setygrid
  • Examples of their effect can be seen above
  • (no gridlines on left, gridlines on right)?

23
Gridlines and EML
  • Gridlines are shown through the showGridlines
    attribute on the axis tag
  • This can be true or false, and is generated
    by elvislib accordingly

24
Multiple ElVis Displays
  • More than one server and/or filename
  • A filename beginning with '/' or '.'
  • A hostname or IP
  • localhost
  • (uses the current computer as the host)?
  • stderr or stdout
  • filegen automatically generates a
  • filename with PID, application name,
  • and username

25
Multiple ElVis Displays, contd.
  • Changes in code
  • In graphwindow.c
  • ef_initialize() now handles ElVis output
    environment variable exclusively
  • initialize() was changed to use an index to find
    a certain output an index to
  • find a certain output
  • ef_GraphWindowSendEML() now loops through all
    outputs, sends EML to each
  • In binio.c
  • binio_set_gwFile() added to set gwfile in binio.c
  • Challenges
  • The mechanism for sending output to a file had to
    be circumvented
  • with binio_set_gwFile()?
  • All other uses of environment variables removed
    or changed

26
Acknowledgments
  • Doug McCune, TRANSP developer, my mentor
  • Eliot Feibush ElVis creator and developer, my
    mentor
  • Andrew Zwicker, Christine Ritter, James Morgan
    PPPL Science Education Program
  • Eric Zatz ElVis Display-side EML Developer

27
Questions?
28
Eric Zatz -CPPG summer undergrad
ElVis Mark-Up Language
Eliot - Mentor
Ben API, EML
Matt System Services
Doug Mentor CPPG Group Head
Mike Movie Making
User Enhancements Tutorials
Write a Comment
User Comments (0)
About PowerShow.com