Skip to main content

BareMetalML

BareMetalML is a lightweight, modular machine learning library built from scratch in Python by Askari Abidi.
It is designed for learning, experimentation, and educational purposes, providing a clear and simple interface for core machine learning algorithms and preprocessing tools.
All models and transformers are implemented using pure NumPy, making the library easy to understand and extend.


Features

Easy and Modular Imports

BareMetalML allows modular imports, so you don’t need to worry about the internal file structure.
For example, you can import any model or transformer like this:

from baremetalml import LinearRegression, StandardScaler

No need to know which file the class is defined in — everything is ready to use.

Core Models

Linear Regression – Ordinary Least Squares (Normal Equation) and Gradient Descent methods

Logistic Regression – Binary classification with Gradient Descent optimization

K-Nearest Neighbors (KNN) – Classification and Regression with multiple distance metrics

Preprocessing & Transformers

StandardScaler – Standardizes features to mean=0, standard deviation=1

NormalScaler – Min-max scaling to [0,1]

LabelEncoder – Converts categorical labels to integers

OneHotEncoder – Converts categorical features into one-hot encoded vectors

PolynomialFeatures – Generates polynomial and interaction features up to a given degree

Base Classes

BaseModel – Abstract base class for all models with input validation

BaseTransformer – Abstract base class for all transformers with fit, transform, and fit_transform interface

What’s Inside

BareMetalML includes:

All basic regression and classification models to start learning ML from scratch

Preprocessing tools for handling numerical and categorical data

Feature engineering utilities like polynomial feature generation

Modular structure for easy imports and extensibility

Installation

BareMetalML is available on PyPI. Install it with:

pip install baremetalml

Then import the modules you need:

from baremetalml import LinearRegression, StandardScaler, KNNClassifier

Author

Askari Abidi

Contribute & Support

BareMetalML is an open-source educational project.

Feel free to contribute, suggest improvements, or report issues on the repository.

If you find it useful, you can support the project via donations or by sharing it with others. Every contribution helps make learning ML from scratch easier and more accessible!

Metadata

Release files for baremetalml 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for baremetalml 1.0.0
File Size Uploaded Provenance
baremetalml-1.0.0.tar.gz 11.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for baremetalml 1.0.0
File Interpreter ABI Platform
baremetalml-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 22.6 kB

Release files / baremetalml-1.0.0.tar.gz

Download URL baremetalml-1.0.0.tar.gz
Size 11.4 kB
Tags Source
SHA-256 checksum
How to use checksums
23432a62ae4ab9e4912d3310cb8ebe3c802084b774c2ea34066fcc52c9e78e39
BLAKE2b-256 checksum
How to use checksums
6c5b98784b65eb68580a99f47b6018da15c84e06982f91534221a19219961cb5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release files / baremetalml-1.0.0-py3-none-any.whl

Download URL baremetalml-1.0.0-py3-none-any.whl
Size 11.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dddd2e5bb32310c05768d0583536f72cdd823169131c8fb41686f17e42f77118
BLAKE2b-256 checksum
How to use checksums
1814a694f86a0502c0a2369b5148ac0460a7e42d631af8dffce5d97154a36423
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Security for baremetalml 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page