basiscode
Basiscode is a concept and accompanying software library designed to separate algorithmic specifications from the basis in which data is represented. It provides a basis-agnostic intermediate representation and tooling that allow developers to write computations in a canonical form and then transform or optimize them for different basis choices, such as Cartesian coordinates, Fourier bases, or custom orthonormal bases. By abstracting the basis, basiscode aims to improve portability across numerical backends and enable targeted optimizations for specific hardware.
At its core, basiscode treats computations as transformations between basis representations. It supports management of bases,
- Basis-aware representations and a type system that tracks basis context
- Transformation and lowering passes that map high-level operations to basis primitives
- Interoperability with common numeric libraries and data formats
- Performance-oriented scheduling, vectorization, and backend simulations
- Debugging, tracing, and reproducible results across different bases
Applications span linear algebra, signal processing, computer graphics, and scientific computing, with use in machine learning