PyTrilinos: A Python Interface to Trilinos Bill Spotz Sandia National Laboratories Reproducible Research in Computational Geophysics August 31, 2006.

Slides:



Advertisements
Similar presentations
1 Coven a Framework for High Performance Problem Solving Environments Nathan A. DeBardeleben Walter B. Ligon III Sourabh Pandit Dan C. Stanzione Jr. Parallel.
Advertisements

Advanced Computational Software Scientific Libraries: Part 2 Blue Waters Undergraduate Petascale Education Program May 29 – June
1 A Common Application Platform (CAP) for SURAgrid -Mahantesh Halappanavar, John-Paul Robinson, Enis Afgane, Mary Fran Yafchalk and Purushotham Bangalore.
Copyright © 2007 Software Quality Research Laboratory DANSE Software Quality Assurance Tom Swain Software Quality Research Laboratory University of Tennessee.
Getting Started with ITK in Python Language
Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin Company, for the United States Department of Energy’s National Nuclear.
MS17 A Case Study on the Vertical Integration of Trilinos Solver Algorithms with a Production Application Code Organizer: Roscoe A. Bartlett Sandia National.
Systems Analysis and Design in a Changing World, Fifth Edition
CS 591x – Cluster Computing and Programming Parallel Computers Parallel Libraries.
OpenAlea An OpenSource platform for plant modeling C. Pradal, S. Dufour-Kowalski, F. Boudon, C. Fournier, C. Godin.
Dr. Chris Musselle – Consultant R Meets Julia Dr Chris Musselle.
Page 1 Trilinos Software Engineering Technologies and Integration Capability Area Overview Roscoe A. Bartlett Trilinos Software Engineering Technologies.
Page 1 Trilinos Software Engineering Technologies and Integration Capability Area Overview Roscoe A. Bartlett Department.
Wavelet Transforms CENG 5931 GNU RADIO INSTRUCTOR: Dr GEORGE COLLINS.
Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin Company, for the United States Department of Energy’s National Nuclear.
Teuchos: Utilities for Developers & Users November 4 th, 1:15-4:30pm Roscoe Bartlett Mike Heroux Kris Kampshoff Kevin Long Paul Sexton Heidi Thornquist.
Trilinos Package Summary ObjectivePackage(s) Discretizations Meshing & Spatial DiscretizationsphdMesh, Intrepid, Pamgen Time IntegrationRythmos Methods.
Using PyTrilinos 2005 Trilinos Users Group Meeting 1 Nov :30-4:30 Bill Spotz.
HDF5 A new file format & software for high performance scientific data management.
Page 1 Trilinos Software Engineering Status and Future Issues Roscoe A. Bartlett Department of Optimization & Uncertainty.
Taking Ownership of Your Package’s Python Interface 2005 Trilinos Users Group Meeting 31 Oct :15-2:15 Bill Spotz.
Page 1 Trilinos Software Engineering Technologies and Integration Capability Area Overview Roscoe A. Bartlett Department.
Page 1 Trilinos Software Engineering Technologies and Integration Numerical Algorithm Interoperability and Vertical Integration –Abstract Numerical Algorithms.
12 Systems Analysis and Design in a Changing World, Fifth Edition.
Ranga Rodrigo. The purpose of software engineering is to find ways of building quality software.
Parallel Interactive Computing with PyTrilinos and IPython Bill Spotz, SNL (Brian Granger, Tech-X Corporation) November 8, 2007 Trilinos Users Group Meeting.
Trilinos 101: Getting Started with Trilinos November 6, :30-9:30 a.m. Jim Willenbring Mike Heroux (Presenter)
Trilinos Progress, Challenges and Future Plans Michael A. Heroux Sandia National Laboratories Sandia is a multiprogram laboratory operated by Sandia Corporation,
Strategic Goals: To align the many efforts at Sandia involved in developing software for the modeling and simulation of physical systems (mostly PDEs):
Amesos Sparse Direct Solver Package Ken Stanley, Rob Hoekstra, Marzio Sala, Tim Davis, Mike Heroux Trilinos Users Group Albuquerque 3 Nov 2004.
Computational Methods of Scientific Programming Lecturers Thomas A Herring, Room A, Chris Hill, Room ,
1 ModelEvaluator Scalable, Extendable Interface Between Embedded Nonlinear Analysis Algorithms and Applications Roscoe A. Bartlett Department of Optimization.
Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin Company, for the United States Department of Energy’s National Nuclear.
Applied Computing Technology Laboratory QuickStart C# Learning to Program in C# Amy Roberge & John Linehan November 7, 2005.
Trilinos Overview and Future Plans Michael A. Heroux Sandia National Laboratories Sandia is a multiprogram laboratory operated by Sandia Corporation, a.
Solvers Made Easy (to use and use together) Thyra, Stratimikos, Handles and More... Roscoe A. Bartlett Department of Optimization & Uncertainty Estimation.
PyTrilinos: a Python Interface to Selected Trilinos Packages Bill Spotz Trilinos Users Group Meeting November 2, 2004.
An Overview of the Thyra Interoperability Effort Current Status and Future Plans Roscoe A. Bartlett Department 1411: Optimization and Uncertainty Estimation.
Amesos Sparse Direct Solver Package Tim Davis, Mike Heroux, Rob Hoekstra, Marzio Sala, Ken Stanley, Heidi Thornquist, Jim Willenbring Trilinos Users Group.
1 SciDAC TOPS PETSc Work SciDAC TOPS Developers Satish Balay Chris Buschelman Matt Knepley Barry Smith.
A Current Overview of the Trilinos Project Jonathan Hu Tenth Copper Mountain Conference on Iterative Methods Monday, April 7 th, 2008 SAND# C.
Scalable Linear Algebra Capability Area Michael A. Heroux Sandia National Laboratories Sandia is a multiprogram laboratory operated by Sandia Corporation,
Thyra from a Developer's Perspective Roscoe A. Bartlett Department 1411: Optimization and Uncertainty Estimation Sandia National Laboratories Sandia is.
Earth System Modeling Framework Python Interface (ESMP) October 2011 Ryan O’Kuinghttons Robert Oehmke Cecelia DeLuca.
New Features in ML 2004 Trilinos Users Group Meeting November 2-4, 2004 Jonathan Hu, Ray Tuminaro, Marzio Sala, Michael Gee, Haim Waisman Sandia is a multiprogram.
An Overview of Trilinos Michael A. Heroux Sandia National Laboratories Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin.
1 Stratimikos Unified Wrapper to Trilinos Linear Solvers and Preconditioners Roscoe A. Bartlett Department of Optimization & Uncertainty Estimation Sandia.
Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin Company, for the United States Department of Energy’s National Nuclear.
Teuchos: Utilities for Developers & Users November 2nd, 3:30-4:30pm Roscoe Bartlett Mike Heroux Kris Kampshoff Kevin Long Paul Sexton Heidi.
CCA Common Component Architecture CCA Forum Tutorial Working Group CCA Status and Plans.
Cracow Grid Workshop, November 5-6, 2001 Concepts for implementing adaptive finite element codes for grid computing Krzysztof Banaś, Joanna Płażek Cracow.
Thyra For Developers Roscoe A. Bartlett Department of Optimization & Uncertainty Estimation Sandia National Laboratories Trilinos Users Group Meeting (Developers.
Mantid Stakeholder Review Nick Draper 01/11/2007.
Linear Algebra Libraries: BLAS, LAPACK, ScaLAPACK, PLASMA, MAGMA
Photos placed in horizontal position with even amount of white space between photos and header Sandia National Laboratories is a multi-program laboratory.
ML: A Multilevel Preconditioning Package Copper Mountain Conference on Iterative Methods March 29-April 2, 2004 Jonathan Hu Ray Tuminaro Marzio Sala Sandia.
Algebraic Solvers in FASTMath Argonne Training Program on Extreme-Scale Computing August 2015.
Combining Trilinos Packages To Solve Linear Systems Michael A. Heroux Sandia National Labs.
C OMPUTATIONAL R ESEARCH D IVISION 1 Defining Software Requirements for Scientific Computing Phillip Colella Applied Numerical Algorithms Group Lawrence.
What’s New for Epetra Michael A. Heroux Sandia National Laboratories Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin.
CIS 595 MATLAB First Impressions. MATLAB This introduction will give Some basic ideas Main advantages and drawbacks compared to other languages.
Page 1 Open-Source Software for Interfacing and Support of Large-scale Embedded Nonlinear Optimization Roscoe A. Bartlett
DOE/Office of Science/ASCR (Sandia National Laboratories)
C Software Life-cycle and Integration Issues for CS&E R&D Software and Experiences from Trilinos (Part I) Roscoe A. Bartlett
A survey of Exascale Linear Algebra Libraries for Data Assimilation
Shrirang Abhyankar IEEE PES HPC Working Group Meeting
ModelEvaluator Scalable, Extendable Interface Between Embedded Nonlinear Analysis Algorithms and Applications Roscoe A. Bartlett Department of Optimization.
Python for Scientific Computing
Trilinos Software Engineering Technologies and Integration
Embedded Nonlinear Analysis Tools Capability Area
Presentation transcript:

PyTrilinos: A Python Interface to Trilinos Bill Spotz Sandia National Laboratories Reproducible Research in Computational Geophysics August 31, 2006

Computational Sciences at Sandia Chemically reacting flows Climate modeling Combustion Compressible flows Computational biology Electrical modeling Heat transfer Load balancing Materials modeling MEMS modeling Mesh generation Optimization and uncertainty quantification Seismic imaging Shock and multiphysics Structural dynamics

The Trilinos Project Provide a central repository for Sandia’s solver technology Increase code-reuse Organized on concept of “packages” Minimize package interdependence Maximize package interoperability Provide a framework for SQE and SQA –Compliance with requirements –Nightly test harness High degree of developer autonomy Open source: GNU Lesser License Web site: Next release: Version 7.0, September, 2006 Trilinos Users Group Meeting, November 7-9, 2006

The Trilinos Project Linear SolversNonlinear Solvers Meta-Solvers Linear Algebra Services Preconditioners Tools & Utilities Amesos AztecOO Belos Komplex Pliris Stratimikos NOX Anasazi Rythmos LOCA MOOCHO Epetra Jpetra Tpetra EpetraExt Kokkos RTOp IFPACK ML Claps Meros Teuchos TriUtils Galeri Thyra Isorropia Moertel Didasko PyTrilinos WebTrilinos New_Package Direct, sparse Iterative, sparse Iterative, sparse, next generation Complex interface to AztecOO Direct, dense Generic interface Communicators, maps, vectors, matrices, graphs… Java Templated Extensions Sparse kernels Reduction, transformation operators Incomplete factorization Multi-levelDomain decomposition Segregated, block Eigensolvers Time-stepping algorithms Continuation algorithms Constrained optimization Primary tools package Common testing toolsMatrix gallery Common interface Partitioning & load balanceMortar elements Trilinos examples Python Interface Web interface Package template

The Interoperability Problem Ross has talked about the need for (and work on) a common abstract interface –Interfaces between Trilinos packages –Interfaces between Trilinos and external packages We would like to extend this concept to the python wrappers –Interoperability with external python projects, such as SLIMpy –Many design decisions still to be made –Some early prototyping work has been done

PyTrilinos Linear Algebra Services –Epetra (with extensive NumPy compatibility and integration) –EpetraExt (coloring algorithms and some I/O) Linear Solvers –Amesos (LAPACK, KLU, UMFPACK, ScaLAPACK, SuperLU, SuperLUDist, DSCPACK, MUMPS) –AztecOO Preconditioners –IFPACK –ML Nonlinear Solvers –NOX (python wrappers not yet caught up to recent redesigns) Meta-Solvers –LOCA (python wrappers not yet caught up to recent redesigns) –Anasazi (early development stage) Tools and Utilities –Teuchos (ParameterList class only) –TriUtils –Galeri –Thyra (early development stage) –New_Package

PyTrilinos Documentation Trilinos documentation is handled by doxygen: special comments within code –Web pages updated twice daily Python wrappers are generated using swig … doxygen does not work with swig interface files –%feature(“autodoc”, “1”); >>> help(Epetra.Vector.Dot) Dot(*args) unbound PyTrilinos.Epetra.Vector method Dot(self, Epetra_Vector A) -> double Currently working to provide much more extensive documentation highlighting differences between C++ and python interfaces –Release 7.0 in September

PyTrilinos.Epetra Communicators –Comm –SerialComm –MpiComm –PyComm Maps –BlockMap –Map –LocalMap Vectors –MultiVector –Vector –IntVector SerialDense objects –SerialDenseOperator –SerialDenseMatrix –SerialDenseVector –SerialDenseSolver –IntSerialDenseMatrix –IntSerialDenseVector Graphs –CrsGraph Operators –Operator –RowMatrix –CrsMatrix

A Quick Detour… Python lists are not suitable for scientific computing –Flexible but inefficient –Heterogeneous data, noncontiguous memory NumPy module provides needed functionality –Contiguous, homogeneous n -dimensional arrays –High-level interface –Part of SciPy SciPy is a large, open source package for a wide variety of python interfaces to scientific software: –NetLib’s “greatest hits”

PyTrilinos.Epetra and NumPy Array-like classes inherit from numpy.UserArray –MultiVector –Vector –IntVector –SerialDenseMatrix –SerialDenseVector –IntSerialDenseMatrix –IntSerialDenseVector Methods throughout Epetra have arguments that accept or produce pointers to C arrays –Python input arguments accept python sequences –Python output arguments produce ndarrays

PyTrilinos.Teuchos PythonDirC / C++ bool  int  float  double string  std::string string  char * dict  ParameterList wrapped ParameterList  ParameterList wrapped PyDictParameterList  ParameterList Teuchos::ParameterList Used by several Trilinos packages to set problem parameters Maps string names to arbitrary-type values Python implementation allows dictionary substitutions Hybrid PyDictParameterList objects are returned The following conversions are supported:

PyTrilinos Demonstration Governing equation: Boundary conditions: Exact solution: CDS: Oscillations:

Conclusions Python lets developers focus on the problem –Memory management, garbage collection –Powerful, flexible containers –Clean, readable syntax PyTrilinos provides access to powerful solver technologies –Rapid prototyping –Application development For computational geophysics, Thyra should provide key too interoperability –Python wrappers for Thyra –Thyra adapters for geophysics codes