40
Enhancements to ElVis Scientific Graphics Software Tarun Pondicherry Ben Phillips PPPL Science Education Summer Interns Eliot Feibush – Mentor August 14, 2007

Enhancements to ElVis Scientific Graphics Software

  • Upload
    hamlin

  • View
    23

  • Download
    0

Embed Size (px)

DESCRIPTION

Enhancements to ElVis Scientific Graphics Software. Tarun Pondicherry Ben Phillips PPPL Science Education Summer Interns Eliot Feibush – Mentor August 14, 2007. ElVis Overview. Java based visualization software, graphs outputs of experiments, analysis, & simulation programs. - PowerPoint PPT Presentation

Citation preview

Page 1: Enhancements to ElVis Scientific Graphics Software

Enhancements to ElVis Scientific Graphics Software

Tarun PondicherryBen Phillips

PPPL Science Education Summer Interns

Eliot Feibush – Mentor

August 14, 2007

Page 2: Enhancements to ElVis Scientific Graphics Software

ElVis Overview

Java based visualization software, graphs outputs of experiments, analysis, & simulation programs.

Accepts input from Data Files

Sockets - APIGUI

Presentation Styles Animated, Surface, Contour, +

Reads data & displays graphs over Internet.

Page 3: Enhancements to ElVis Scientific Graphics Software

Monitor & Display Results

DOE SciDac Fusion Simulations - under developmentCPES SWIM FACETS

Web ServicesReflectometer Simulation (ElFresco) – w3.pppl.gov/fwrTRANSP – RPLOT – beta test / alpha usersGTC – availableShaped GTC – under developmentNova-K – under development

MSETSCSCOPE

Page 4: Enhancements to ElVis Scientific Graphics Software

Summer ‘07

Improvements to visualizing 2-D data sets.

Interactive log plotting.

User requests from applications.

Page 5: Enhancements to ElVis Scientific Graphics Software

Tarun Pondicherry – my work

Develop New Presentation Stylesf(x,i) with color gradientsf(x,y) Continuous color plots (color map)f(x,y,t) Indexed color plots

Implement User Application RequestsAspect Ratio ResizeElVis File Convention AdditionsAnimation Controls

Page 6: Enhancements to ElVis Scientific Graphics Software

Gradient Datasets

• Shows multiple time steps in order in a single view.• Creates a linear gradient from first to last index.• Useful to see how data changes over time.

Animated Presentation Style New Gradient f(x,i)

Page 7: Enhancements to ElVis Scientific Graphics Software

Continuous Color Plot

• Displays a color profile of 2D data.• Similar to contour, but shows all data points.

Existing Contour Plot New Color Map Plot

Page 8: Enhancements to ElVis Scientific Graphics Software

Data Exploration

Displays value as user moves the cursor.

Page 9: Enhancements to ElVis Scientific Graphics Software

Other Interactions

Inherits ElVis interactions (zoom, pan, whiteboard, labels) for exploring and annotating data.

Page 10: Enhancements to ElVis Scientific Graphics Software

Log Scalable

X, Y, and color axes independently scale logarithmically or linearly.

Page 11: Enhancements to ElVis Scientific Graphics Software

New Color Scale Chooser• Allows users to

specify color ranges.• Add, delete or change

a color point.• Useful to draw

attention to particular values.

• Color scale saved in ElVis convention.

Useful for simulations & analysis programs to color-code plasma cross sections.

Page 12: Enhancements to ElVis Scientific Graphics Software

Indexed Color Map• Plots f(x,y,t)• During animation,

moves through time dimension

• Creates images during animation

• Can be made from NetCDF Panel– Supports Templates– Supports NetCDF

File Monitoring

psiRZ for NSTX shot 121137. Data from Rob Andre.

Click on image to play movie.

Page 13: Enhancements to ElVis Scientific Graphics Software

Animated Images

• Saves steps in animated plots as a series of images.

• Can copy and paste all images into PowerPoint at once in order.

• Can easily be made into a wmv file using Windows Movie Maker.

psiRZ over time .01 – .54 seconds

Page 14: Enhancements to ElVis Scientific Graphics Software

Aspect Ratio Resize

• Initial aspect ratio limited to 4:3 paper size graphs.

• Java AffineTransform used for resize --> Distortion

• Users requested gaining resolution and maintaining line width and aspect ratio.

• Now recalculates placement and increases resolution.

• Text aspect ratio also preserved. No distortion.

Before:After:

Page 15: Enhancements to ElVis Scientific Graphics Software

ElVis Convention Additions

• ElVis convention allows users to save and open plots with presentation attributes (color, size, labels, etc.)

• Added functionality to save Contour, Surface, Color Plot, 2D Presentation Styles

Page 16: Enhancements to ElVis Scientific Graphics Software

Animation Controls

Previously ElVis ran animations at the rate they loaded.

My Additional Controls• Runs at user defined frame rate.• Dynamically sets frame rate based on

server speed.• Allows users to drop frames to maintain

time base.

CPES Sim. Vis.GTC Web Service

Page 17: Enhancements to ElVis Scientific Graphics Software

Animation Measurements

Image Download Times for PC cppg-win2:– PPPL ~ 30ms– Rutgers ~ 50ms– Oak Ridge ~ 80ms

Download rate for images stored as URLs

on web servers.

Page 18: Enhancements to ElVis Scientific Graphics Software

Ben Phillips – my work

Logarithmic plotting – graphical interaction.

Improved surface plots of 2-D data sets.

Application-driven features.

Page 19: Enhancements to ElVis Scientific Graphics Software

Challenges of Log Plotting Providing an interactive model

ElVis Requirements

Allow user to fine tune the viewing region• Resize the graph window.• Adjust the scales on the axes.

Prevent user from “getting lost.”

Enable the user to get a digital read out of specific values in a plot.

Cleanly handle plots with values <= 0• Cannot take log of 0 or less.

Page 20: Enhancements to ElVis Scientific Graphics Software

Improvements to Log Plotting

New features I implemented– Extended interactions of linear plots to logarithmic

plots• Tick marks• Zooming• Cursor

– Created methods to handle the limitations of log plotting

Page 21: Enhancements to ElVis Scientific Graphics Software

Major and Minor Tick Marks

• Major tick marks specify decades

(10x, 10x+1, 10x+2, …)• Minor tick marks specify points within a decade

(2*10x, 3*10x, 4*10x, …, 9*10x)

Algorithm translated from rplot sglib

Considers resolution to avoid crowding

Page 22: Enhancements to ElVis Scientific Graphics Software

Zooming – Allows users to examine areas of a log plot

Click and drag region to zoom in. ElVis zooms in on the region and adjusts the axes appropriately.

Page 23: Enhancements to ElVis Scientific Graphics Software

Zooming – Graph must be at least one decade wide and tall

I enforced minimum zooming region shown by red rectangle.This is the actual region that ElVis will display if the user lets go of the mouse.

Page 24: Enhancements to ElVis Scientific Graphics Software

Zooming – Axes limitations

• Users cannot zoom into a region that is less wide or less tall than a decade.

• Floating point precision bounds axes to the interval [10-44, 1038]

Page 25: Enhancements to ElVis Scientific Graphics Software

Cursor – Digital Read Out

Displays data values for each curve.

Page 26: Enhancements to ElVis Scientific Graphics Software

Challenges of Surface Plotting

No 3-D graphics hardware acceleration.– No third party libraries such as Java3D.

• Heavyweight 3D components do not mix with Lightweight Swing components that support overlapping windows.

ElVis must use 100% pure Java implementation in software.– Portable but slower than graphics hardware.– Must run in a browser.– ElVis cannot take advantage of the built-in memory and

processing power present on many graphics cards.

Page 27: Enhancements to ElVis Scientific Graphics Software

My Surface Plot Improvements

Logarithmic scales for axes

Display Optimizations -Surface plots now display faster.Wireframe display during zoom, rotate, or resize.User can customize how much data is displayed dynamically.

Memory Management

Page 28: Enhancements to ElVis Scientific Graphics Software

Log surfaces – Usefulness of log plots brought to three dimensions

All three axes can be set independently to linear or logarithmic scales.

Page 29: Enhancements to ElVis Scientific Graphics Software

Wireframe Display OptimizationFaster to rotate, resize, & zoom

Makes rotating, resizing, and zooming smoother on surface plots.

Page 30: Enhancements to ElVis Scientific Graphics Software

Data Reduction Slider Even faster to rotate, resize, and zoom

Users can control how much data to display while manipulating the surface. Demo

Page 31: Enhancements to ElVis Scientific Graphics Software

Surface graphs can take up a lot of memory!

• Problem is especially acute in Applets where memory is very limited.

• OutOfMemoryErrors crash ElVis– Unacceptable

Page 32: Enhancements to ElVis Scientific Graphics Software

Challenges of Handling Limited Memory

• Java’s garbage collector cannot be run on command.

• Java has a lot of behind-the-scenes implementation details dealing with runtime reflection that make estimating the size of classes difficult.

• OutOfMemoryErrors cannot be caught programmatically.

Page 33: Enhancements to ElVis Scientific Graphics Software

Consquences of Java’s Memory Handling Limitations

• ElVis must make an educated guess at the memory requirement for a Surface plot.– In practice it appears to be accurate to within

10% most of the time (20% off is the worst observed)

• Java memory handling features can still be broken in certain cases.

Page 34: Enhancements to ElVis Scientific Graphics Software

Surface plots are partially displayed when memory is low.

Surface plots are only displayed with some of their polygons in low memory situations.

If available memory becomes extremely low then ElVis does not allow any more Surface plots to be opened.

Page 35: Enhancements to ElVis Scientific Graphics Software

Java Memory Allocation

Click on Run the ElVis Applet: w3.pppl.gov/elvisBrowser applet limited to 64 MB.

Run as application outside of brower = 200 MBclick on Run ElVis

Type in a command line:java -Xms200000000 -Xmx900000000 elviscdf.jar

= 900 MB

Page 36: Enhancements to ElVis Scientific Graphics Software

Adding more memory to Applets (On Windows + Java 1.5 or 1.6)

• Start -> Control Panel -> Java Plug-in -> Java Tab -> View Java Applet Runtime Settings

• Add a Java Runtime Parameter –Xmx[heapsize]m

Example: -Xmx500m makes heap size 500 megabytes for Applets

Java 1.5 can increase to ¼ system memory.

Page 37: Enhancements to ElVis Scientific Graphics Software

Points Editor Edit numerical values

Fix spurious data.Created for fixing input profiles for the Nova-K web service.

Page 38: Enhancements to ElVis Scientific Graphics Software

Layout Manager Adjust the number of rows and columns

Allows for easy manipulation of a large number of graphs.Collect & retain all graphs from an rplot session for comparisons.

Page 39: Enhancements to ElVis Scientific Graphics Software

Acknowledgements

• Thanks to– Eliot Feibush - Mentor, Slidesmith– PPPL Science Education Program:

Christine Ritter, Andrew Zwicker & James Morgan

– Princeton Plasma Physics Lab

Page 40: Enhancements to ElVis Scientific Graphics Software

Summary

Improvements to ElVis foundation classes benefit display programs & web services that include ElVis.

I want to thank Ben & Tarun for all the excellent work they have accomplished this summer.