Extension module for matrix multiplication
Project description
LanaBLAS 🐑
Linear Algebra for nocturnal and adventurous data scientists exploring BLAS
LanaBLAS is a repository primarily used for testing the development of CPython extension modules with external dependencies, such as (OpenBLAS). It's a work-in-progress memetic project aimed at having fun and learning new things.
Install
pip install lanablas==0.1.6
Example
from lanablas import Matrix, inject
a = Matrix.ones(3,3)
print(a)
print(type(a), a.shape)
b = Matrix.eye(3)
print(b)
print(type(b), b.shape)
c = a + b
print(c)
print(type(c), b.shape)
for row in c.tolist():
print(row, type(row))
# sub-matrix
d = Matrix.new(inject(c.tolist()[0]))
print(type(d), d.shape)
For more comprehensive examples, please visit the examples folder
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
lanablas-0.1.6.tar.gz
(71.4 MB
view hashes)
Built Distribution
Close
Hashes for lanablas-0.1.6-cp39-cp39-macosx_13_0_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d345e0a52c22784a6b994671cdd798f287f3b8997f49a568dc0b882820ddac86 |
|
MD5 | 9f3991011da3d9aeb16f56a4cf4dad7a |
|
BLAKE2b-256 | c07538fba21dc935b00709247a505dbf9c8d1881938b4517da8915be3c1e2576 |