magicl
OpenBLAS
Our great sponsors
magicl | OpenBLAS | |
---|---|---|
14 | 22 | |
225 | 5,952 | |
0.4% | 2.4% | |
5.4 | 9.8 | |
6 months ago | 4 days ago | |
Common Lisp | C | |
BSD 3-clause "New" or "Revised" License | BSD 3-clause "New" or "Revised" License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
magicl
-
A tutorial quantum interpreter in 150 lines of Lisp
(Link didn't work for me)
https://github.com/quil-lang/magicl/blob/master/src/high-lev...
-
Why Lisp?
use MAGICL. [1] It is optionally and transparently accelerated by BLAS/LAPACK.
[1] https://github.com/quil-lang/magicl/blob/master/doc/high-lev...
-
How fast can you multiply matrices using only common lisp?
Maybe have a look at how magicl does this?
-
A software engineer's circuitous journey to calculate eigenvalues
This is essentially the first option, which is already supported by MAGICL by loading MAGICL/EXT-LAPACK [1].
[1] https://github.com/quil-lang/magicl#extensions
-
Uncle Stats Wants You
I think what the magicl team has done is brilliant - allowing multiple implementations is awesome.
-
Good Lisp libraries for math
Second up is magicl, especially useful if performance is a concern. This might not be as extensive as numcl, but it's been battle tested in the industry over the last decade or so. Because this uses generic functions, so long as you are using not-very-small arrays, performance should not be a concern for you. And even if you are, you could write your own functions that use the low-level functions that magicl's backends define. Otherwise performance can be at par with numpy.
-
Why is python numpy *so* much faster than lisp in this example?
This Dev How-To describes (I hope in enough detail) how to add these specialized routines to MAGICL.
-
CL-AUTOWRAP generated (C)BLAS wrapper in QUICKLISP
I agree... and I do don't want be the person who has not rallied. I just took a look at guicho's issue from 2019. And here, you yourself have admitted that the high level interface is less than ideal and needs more work. However, the very point that magicl is an industry standard could imply that potentially radical backward-incompatible changes can be hard. But, honestly, I want to discuss this, time permitting!
- Fast and Elegant Clojure: Idiomatic Clojure without sacrificing performance
-
Anybody using Common Lisp or clojure for data science
Common Lisp is a great language to build new tools for data science, but currently has pretty awful library support existing data science workflows. Common Lisp is sorely lacking in high-quality statistics, plotting, and sparse arrays. There’s been a long work-in-progress library to bring flexible and high-performance linear algebra to Lisp, but it needs more contributors.
OpenBLAS
-
LLaMA Now Goes Faster on CPUs
The Fortran implementation is just a reference implementation. The goal of reference BLAS [0] is to provide relatively simple and easy to understand implementations which demonstrate the interface and are intended to give correct results to test against. Perhaps an exceptional Fortran compiler which doesn't yet exist could generate code which rivals hand (or automatically) tuned optimized BLAS libraries like OpenBLAS [1], MKL [2], ATLAS [3], and those based on BLIS [4], but in practice this is not observed.
Justine observed that the threading model for LLaMA makes it impractical to integrate one of these optimized BLAS libraries, so she wrote her own hand-tuned implementations following the same principles they use.
[0] https://en.wikipedia.org/wiki/Basic_Linear_Algebra_Subprogra...
[1] https://github.com/OpenMathLib/OpenBLAS
[2] https://www.intel.com/content/www/us/en/developer/tools/onea...
[3] https://en.wikipedia.org/wiki/Automatically_Tuned_Linear_Alg...
[4]https://en.wikipedia.org/wiki/BLIS_(software)
- Assume I'm an idiot - oogabooga LLaMa.cpp??!
-
Learn x86-64 assembly by writing a GUI from scratch
Yeah. I'm going to be helping to work on expanding CI for OpenBlas and have been diving into this stuff lately. See the discussion in this closed OpenBlas issue gh-1968 [0] for instance. OpenBlas's Skylake kernels do rely on intrinsics [1] for compilers that support them, but there's a wide range of architectures to support, and when hand-tuned assembly kernels work better, that's what are used. For example, [2].
[0] https://github.com/xianyi/OpenBLAS/issues/1968
[1] https://github.com/xianyi/OpenBLAS/blob/develop/kernel/x86_6...
[2] https://github.com/xianyi/OpenBLAS/blob/23693f09a26ffd8b60eb...
-
AI’s compute fragmentation: what matrix multiplication teaches us
We'll have to wait until part 2 to see what they are actually proposing, but they are trying to solve a real problem. To get a sense of things check out the handwritten assembly kernels in OpenBlas [0]. Note the level of granularity. There are micro-optimized implementations for specific chipsets.
If progress in ML will be aided by a proliferation of hyper-specialized hardware, then there really is a scalability issue around developing optimized matmul routines for each specialized chip. To be able to develop a custom ASIC for a particular application and then easily generate the necessary matrix libraries without having to write hand-crafted assembly for each specific case seems like it could be very powerful.
[0] https://github.com/xianyi/OpenBLAS/tree/develop/kernel
-
Trying downloading BCML
libraries mkl_rt not found in ['C:\python\lib', 'C:\', 'C:\python\libs'] ``` Install this and try again. Might need to reboot, never know with Windows https://www.openblas.net/
-
The Bitter Truth: Python 3.11 vs Cython vs C++ Performance for Simulations
There isn't any fortran code in the repo there itself but numpy itself can be linked with several numeric libraries. If you look through the wheels for numpy available on pypi, all the latest ones are packaged with OpenBLAS which uses Fortran quite a bit: https://github.com/xianyi/OpenBLAS
- Optimizing compilers reload vector constants needlessly
-
Just a quick question, can a programming language be as fast as C++ and efficient with as simple syntax like Python?
Sure - write functions in another language, export C bindings, and then call those functions from Python. An example is NumPy - a lot of its linear algebra functions are implemented in C and Fortran.
- OpenBLAS - optimized BLAS library based on GotoBLAS2 1.13 BSD version
-
How to include external libraries?
Read the official docs yet?
What are some alternatives?
lisp-matrix - A matrix package for common lisp building on work by Mark Hoemmen, Evan Monroig, Tamas Papp and Rif.
Eigen
py4cl - Call python from Common Lisp
GLM - OpenGL Mathematics (GLM)
criterium - Benchmarking library for clojure
cblas - Netlib's C BLAS wrapper: http://www.netlib.org/blas/#_cblas
Petalisp - Elegant High Performance Computing
blaze
hash-array-mapped-trie - A hash array mapped trie implementation in c.
Boost.Multiprecision - Boost.Multiprecision
april - The APL programming language (a subset thereof) compiling to Common Lisp.
ceres-solver - A large scale non-linear optimization library