Matthew Bennett

Logo

I am a data scientist working on time series forecasting (using R and Python 3) at the London Ambulance Service NHS Trust. I earned my PhD in cognitive neuroscience at the University of Glasgow working with fmri data and neural networks. I favour linux machines, and working in the terminal with Vim as my editor of choice.

View my GitHub Profile

View my LinkedIn Profile

View my CV

Building a Python 3 Numpy-like library from scratch

The full code I’ve written so far can be found here.

Also see my related project: Adding a statistics sub-package

I want to improve my knowledge of classes, objects, functions and methods in Python 3 and to gain a better understanding of the 'standard practices' associated with writing them. So I've decided to try and build a Python library that allows me to do linear algebra operations - something like the popular Numpy module, but of course much smaller in scope. As a bonus, it will allow me to consolidate my recent studies of linear algebra. I will attempt to implement all the linear algebra operations, methods and algorithms covered in Gilbert Strang's Introduction to linear algebra. As much as possible, I will use Python's standard library. N.B. I do use copy.deepcopy (imported as dc) in a few places to avoid side effects (altering mutable objects passed as arguments).

Class, methods and functions to implement

Below is a list of the topics I've covered in my studies so far, and which I will attempt to realise in my library.

Class, standalone functions and miscellaneous methods

Fundamental methods

Secondary methods

Dependencies between methods

The dependencies among the above methods are depicted by a weighted graph:

Code dependency

back to home