Advertisement

Gajit: Symbolic Optimisation and JIT Compilation of Geometric Algebra in Python with GAALOP and Numba

  • Hugo HadfieldEmail author
  • Dietmar Hildenbrand
  • Alex Arsenovic
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 11542)

Abstract

Modern Geometric Algebra software systems tend to fall into one of two categories, either fast, difficult to use, statically typed, and syntactically different from the mathematics or slow, easy to use, dynamically typed and syntactically close to the mathematical conventions. Gajit is a system that aims to get the best of both worlds. It allows us to prototype and debug algorithms with the Python library clifford [1] which is designed to be easy to read and write and then to optimise our code both symbolically with GAALOP [2] and via the LLVM pipeline with Numba [3] resulting in highly performant code for very little additional effort.

Keywords

Geometric Algebra Conformal geometry Symbolic optimisation Just in time compilation 

References

  1. 1.
    Arsenovic, A., Hadfield, H., Kern, R.: The Pygae Team. pygae/clifford: v1.0.1, October 2018Google Scholar
  2. 2.
    Schwinn, C.: Gaalop 2.0 - a geometric algebra algorithm compiler (2010)Google Scholar
  3. 3.
    Lam, S.K., Pitrou, A., Seibert, S.: Numba: a LLVM-based python JIT compiler. In: Proceedings of the Second Workshop on the LLVM Compiler Infrastructure in HPC - LLVM 15, pp. 1–6. ACM Press (2015)Google Scholar
  4. 4.
    De Keninck, S.: ganja.js (2017)Google Scholar
  5. 5.
    Perwass, C.: Geometric Algebra with Applications in Engineering. Springer, Heidelberg (2009).  https://doi.org/10.1007/978-3-540-89068-3CrossRefzbMATHGoogle Scholar
  6. 6.
    Colapinto, P.: VERSOR: spatial computing with conformal geometric algebra. Master’s thesis, University of California at Santa Barbara (2011). http://versor.mat.ucsb.edu
  7. 7.
    Leopardi, P.C.: GluCat home page (2001). http://glucat.sourceforge.net/
  8. 8.
    Breuils, S., Nozick, V., Fuchs, L.: Garamon: Geometric algebra library generator. In: AGACSE 2018 (2018)Google Scholar
  9. 9.
    Fontijne, D.: Gaigen 2: a geometric algebra implementation generator. In: Proceedings of the 5th International Conference on Generative Programming and Component Engineering - GPCE06, p. 141. ACM Press (2006)Google Scholar
  10. 10.
    Hildenbrand, D., Fontijne, D., Wang, Y., Alexa, M., Dorst, L.: Competitive runtime performance for inverse kinematics algorithms using conformal geometric algebra. In: Eurographics Conference Vienna (2006)Google Scholar
  11. 11.
    Hildenbrand, D.: Geometric computing in computer graphics and robotics using conformal geometric algebra. Ph.D. thesis, TU Darmstadt, Darmstadt University of Technology (2006)Google Scholar
  12. 12.
    Woersdoerfer, F., Stock, F., Bayro-Corrochano, E., Hildenbrand, D.: Optimization and performance of a robotics grasping algorithm described in geometric algebra. In: Iberoamerican Congress on Pattern Recognition 2009, Guadalajara, Mexico (2009)Google Scholar
  13. 13.
    Hildenbrand, D.: Foundations of Geometric Algebra Computing. Springer, Heidelberg (2013).  https://doi.org/10.1007/978-3-642-31794-1CrossRefzbMATHGoogle Scholar
  14. 14.
    Hildenbrand, D., Albert, J., Charrier, P., Steinmetz, C.: Geometric algebra computing for heterogeneous systems. Adv. Appl. Clifford Algebras J. (2016)Google Scholar
  15. 15.
    Aho, A.V., Lam, M.S., Sethi, R., Ullman, J.D.: Compilers: Principles, Techniques, and Tools, 2nd edn. Addison-Wesley Longman Publishing Co., Inc., Boston (2006)zbMATHGoogle Scholar
  16. 16.
    Kennedy, K., Allen, J.R.: Optimizing Compilers for Modern Architectures: A Dependence-Based Approach. Morgan Kaufmann Publishers Inc., San Francisco (2002)Google Scholar
  17. 17.
    Bolz, C.F., Rigo, A.: How to not write virtual machines for dynamic languages. In: ESUG 2007 (2007)Google Scholar
  18. 18.
    Oliphant, T.E.: Guide to NumPy, 2nd edn. CreateSpace Independent Publishing Platform, Scotts Valley (2015)Google Scholar
  19. 19.
    Jones, E., Oliphant, T., Peterson, P., et al.: SciPy: open source scientific tools for Python (2001)Google Scholar
  20. 20.
    Lattner, C., Adve, V.: LLVM: a compilation framework for lifelong program analysis & transformation. In: International Symposium on Code Generation and Optimization, CGO 2004, pp. 75–86. IEEE (2004)Google Scholar
  21. 21.
    Perwass, C.: The CLU home page (2010). http://www.clucalc.info

Copyright information

© Springer Nature Switzerland AG 2019

Authors and Affiliations

  1. 1.Cambridge University Engineering DepartmentCambridgeUK
  2. 2.University of Technology DarmstadtDarmstadtGermany
  3. 3.810 LabsStanardsvilleUSA

Personalised recommendations