1 / 24

Rich Client Platform for Synchrotron Science

Rich Client Platform for Synchrotron Science. An open source not for profit project On GitHub ‘ DawnScience ’ - Diamond Light Source Ltd. and the ESRF are largely publically funded research facilities. Disclaimer AKA - who says that?.

olina
Download Presentation

Rich Client Platform for Synchrotron Science

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Rich Client Platform for Synchrotron Science • An open source not for profit project • On GitHub ‘DawnScience’ • - Diamond Light Source Ltd. and the ESRF are largely publically funded research facilities

  2. DisclaimerAKA - who says that? • A Java Software Developer (not a Scientist) worked for 14 years with various Java based applications. • An Eclipse/RCP fan • I will attempt to explain a bit of the science for your enjoyment (hopefully not schadenfreude). • The rest of the talk will focus on software. • The eclipse features shown in this talk, such as the pipelining tools can be reused outside Science. • Matthew Gerring

  3. SynchrotronAKA – cool word, but what does it mean? syn·chro·tron/ˈsiNGkrəˌträn/ Noun:Acyclotron in which the magnetic field strength increases with the energy of the particles to keep their orbital radius constant. “They are machines which produce very strong light used for many different type of scientific experiments and sometimes other things.”

  4. Diamond (User Facility) ESRF (Experimental Facility)

  5. The Queen and Duke of Edinburgh at the official opening of DLS, 19th October 2007

  6. Scientists with some of the hardware used in their research Inside the storage ring [not star-trek “conduit”...] Video of Diamond...

  7. Detectors of Various flavours

  8. ResponsibilitiesAKA – what developers do there... • Software for controlling experiments • Motors, detectors, data collection scripts, configuration. • A high quality but flexible GUI. • Software for data • Ability to visually interact with n-dimensional data (i.e. graphs and slices). • Ability to write scripts to interact with data. • Custom user interface and forms for specific experiments. • Software for running analysis during experiments • Workflow and pipelines. Hard coded and/or user configurable options. • Real time visualization of analysed results.

  9. Integration ToolsAKA – how we are getting it done • EIDES – Eclipse IDE, Stupid - around 20 developers, 8 in scientific software • Eclipse RCP product built using Buckminster (previously PDE) • Usage of Jenkins for continuous integration. Specific releases still produced and tested, appearing as separate items in Jenkins. • Unit tests using Squish UI Testing, Junit and Junit plugin tests. • We do not currently do code walkthroughs or pair programming. Agile practices being used where otherwise possible. • We document our designs and code using confluence. • We use Cheat Sheets for tutorials and testing guides.

  10. Git / eGit in late 2011AKA – no body expects the Spanish Inquisition

  11. ‘Shoulders of Giants’AKA – didn’t think of everything • RCP many of the core features, editors, toolbars, views, projects • Ptolemy 2 (a version known as ‘Passerelle’) workflow and pipelining • GEF for visualization of pipeline graphs • Draw2D for 1D and 2D plotting (SWT XY Graph) • Pydev for python/jython scripting layer used by the scientists • HDF5 libraries for storing large data sets • SWT/Jface – lazy viewers being used extensively for large trees and tables • Apache, Eclipse-WST, springsource, JDK, and many more of course...

  12. A quick look at lazy What it does Things to do in the source code tree = newTreeViewer(parent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.FULL_SELECTION | SWT.BORDER |SWT.VIRTUAL); tree.setUseHashlookup(true); publicclassFileContentProviderimplementsILazyTreeContentProvider { ... } tree.setContentProvider(new FileContentProvider()); tree.getTree().setItemCount(...); • Viewer reads contents as incrementally (normal, however...) • Items off screen not loaded • Not icon read, no label • Resources for the item unassigned • Allows large viewer contents to exist but not take up resources until used

  13. Lots of Visual Tools • For images • Line, Box, Sector integration • Diffraction image interpretation, line profile for ‘D-spacing’ • Color mapping / Histogramming • Pixel Information and region control • For XY Graphs • Peak Fitting and Line Fitting • Derivative and other functions, including user defined • Scientific tools • XAFS Analysis Tool • SAXS • Use of eclipse architecture, extension points and pages inside PageBookView.

  14. Demonstration – Visual Tools Example showing various visual tools

  15. Slicing data • Cutting through N-dimensional data • With an XY plot • As an image • As a 3D iso-surface • Hyper 3D • Important to run everything concurrently • Use of Jobs • Use of ordinary threads • Use of blocking queues of various sizes • Third party native APIs using Bundle-NativeCode

  16. Demonstration – Slicing and dicing Example opening a tomography file and slicing it

  17. Demonstration – Tools and Hyper 3D Example showing slicing data using Hyper 3D on a human skull

  18. Pydev and Python • Have you heard of Pydev? (Have you heard of python?) • Diamond is one of the largest contributors to Pydev. • Able to integrate Python numpy, scipy with our plotting • Able to debug interactive python • Python very popular with scientific programmers (because they are slow typers).

  19. Demonstration – Python Integration Example showing connection to python

  20. Pipelines / workflows based on Passerelle Ptolemy II Eclipse GEF (soon to be Graphiti) EMF / GMF replaced with Ptolemy II • Eclipse feature, EPL /Apache dependencies • Easy to create multi-threaded algorithms using branches • Balance over multi-CPU systems using JDK threading • Runs in separate process using Eclipse debug plugins • Easy to integrate new actors (extension points) RCP application

  21. Demonstration – Simple Matrix Maths Add, subtract – etc some images produced by an experiment...

  22. Fridge Control Example • Controlling a fridge using Ptolemy II • Adding and running your own actors • The actors sleep instead of doing things Taken from examples on our github repo ‘DawnScience’

  23. Demonstration – Acme fridge control Example using actors which control a fridge, for instance

  24. Conclusion • Thanks to Eclipse for providing a great tool • RCP is fast and scalable too, using OSGI • SWT has ability to be configured for very large data • Ability to integrate native code in plugins if needed • Maybe we can support web application with RAP one day • Thanks to the Java community for its APIs • We will hopefully be an eclipse project one day... • Thanks for listening and please approach me at the conference if you want to talk about things Diamond Light Source Ltd. www.diamond.ac.uk ESRF www.esrf.fr Data Analysis Workbench, www.dawnsci.org

More Related