My Machine Learning (MML) Library, a high performance machine learning and deep learning framework coding from scratch (pure Python) with hybrid backend support (`numpy` or `torch`).. Write `import mml` to use it.
Project description
MML (mml-pypi)
My Machine Learning (MML) Library developed by Nathmath and DOF Studio, identified as mml-pypi on PyPI.
What is MML? Why MML?
-
It is a high performance machine learning and deep learning framework coding from scratch (pure Python) with hybrid backend support (
numpyortorch). -
It is a pure Python implementation and almost has production level performance (significantly higher in neural nets) as fantastic toolkit for
quick application,library comparision, andquick benchmarkingwith. -
It is a package with utilities covering from Data IO, Feature Engineering, and Data Transforming, not only and far from simply a machine learning library, but a deeply integrated environment you can do everything on one set.
-
Its code is completely light-weight and open-source suitable for teaching, learning, deploying, and even debugging. You will never forget how
integrated,simple, andpowerfulMML can be before starting to code on it. -
Its style is designed for experts as well as non-experts -- we have a complete set of nn modules and
Auto Neural Networkframework, which can automaticallybuild,train,fine-tune, andevaluatea neural network natively useful for non-technical groups.
Latest Version: 0.0.5
For more information:
-
GitHub homepage: https://github.com/dof-studio/MML
-
PyPI homepage: https://pypi.org/project/mml-pypi
How to Start
# bash:
pip install mml-pypi
# Python:
import mml
# For further tutorials, see `./document`
# Recommend to start from `1. General.md` and try the must-run example first.
Update History
MML 0.0.5 Release:
- Minor bugs fixed.
- Some document updates.
- New methods
erfanderfinvare provided inMatrixandTensorcontainers. - New Activations like
GELU,ELU,SELU,SiLU, ... are implemented. - More abbreviations like
RM,BCM,MCM,BCE,MCE... are included. - Global support of better Auto-Encoder arch by introducing a
forward_encodermethod from the basenn_Module, andpredict_encoderinEvaluator. - Global support of
Auto ForwardandAuto Backwardsystems. Users can only define a sequential network in__init__without concerning its forward and backward passes by manual labor. - Formal introduction of
Auto Neural Networksystem, supportingtabularandtime-seriesdata modelling (will be continuously updating in the future). - Try
nn.AutoNNnow!
Planned Updates:
Within 0.0.5.x:
-
More Document updates.
-
Cliplayer, manually supports clipping to avoid overfitting in classification tasks. -
Reshapelayer, a generic reshaping tool supplementary to the currentFlatten. -
Poolinglayers, useful in CNN or LSTM related architectures. -
GRUlayers, serves as a simpler version of LSTM. -
Introduce
Dropoutlayers between Recurrent blocks. -
More
Lossfunctions likeWMSE,WRMSE, etc. to support weighted average. -
More
Lossfunctions designed for financial engineers to develop strategies. -
Kernel PCAimplementation for simpler but stronger dimensionality reduction. -
KNNandK-meansalgorithms for regression and clustering. -
More
AutoNNarchitecture and tasks support.Later versions:
-
Attentionmodule, which is regarded by someone asAll You Need. -
Conv1DandConv2Dlayers and pre-trained models (likeMobileNet) for audio and image neural network tasks. -
Auto Neural Networksupport for audio and image style tasks. -
GANandRLframework, incorporated into the current Neural Network framework. -
More
AutoNNarchitecture and tasks support.
Version Control
From versions later than 0.0.5, Viewable Version Control (VVC) tools will be installed with this library. With VVC
enabled, you can clear filter and see what has changed on a specific function or argument from a specific version to a specific version. Database will record any change starting from version 0.0.5.1 (next minor update to 0.0.5).
- Note:
Viewable Version Control (VVC)is also aDOF Studioowned open-source repository. - See
https://github.com/dof-studio/VVCfor more information about using this version control tool.
License
Apache 2.0 License, with no warranty but grants the right for even commercial use.
What's Inside?
-
Containers.
-
ML Algorithms.
-
Neural Network Framework (and Simple Interfaces).
-
Utilities and Toolkits.
-
Free ML Tutorial, Project Examples, and Documents.
Everything coded from scratch!
See below for a quick and complete reference.
Containers using Mixed Backends
- Matrix (n-dimensional, For ML Algorithms) (NumPy √ Torch √)
- Tensor (n-dimensional, For NN Framework) (NumPy √ Torch √)
ML Algorithms from Scratch
- Linear Models (OLS and FGLS)
- Generalized Linear Models (FGLS with Activation)
- Time Series Models (TS, ARIMAX)
- Principal Component Analysis (PCA)
- Support Vector Machine (SVM)
- Classification And Regression Tree (CART)
- Linear Regression Tree Wrapper (LRTW)
- Random Forest (RF)
- Gradient Boosting Machine (GBM)
- Extreme Gradient Boosting Machine (XGBM)
- ...
Neural Network Framework from Scratch
- Basic Overridable Neural Network Module (Module)
- Dense Layer (Dense)
- Dropout Layer (Dropout)
- Flatten Layer (Flatten)
- Single or Stacked RNN Layer (RNN)
- Single or Stacked LSTM Layer (LSTM)
- Activation Layers (ReLU, LeakyReLU, ELU, SELU, GELU, SiLU, ...)
- Loss Functions (MSE, RMSE, MAE, BCE, MCE, ...)
- Optimizers (SGD, Adam, AdamW, ...)
- Easy Interface for Evaluation (Evaluator)
- Auto Neural Network Framework (AutoNN)
- ...
Utilities from Scratch
- Regression, Binary Classification, Multi Classification Metrics
- Train-Test Split, Train-Test Split for Time Series, Rolling Window Maker
- Data Scaler
- Data Wrangling Toolkits
- Easy Save and Load Interface
- Generic Optimizer
- Generic Bootstrap Sampler
- ...
Documentation in Detail (Updating)
See ./document for more information.
Recommended learning curve:
1. General.md2. Containers.md3. Machine Learning Models.md4. Neural Netwotk Framwwork.md5. Simple Interface and AutoNN System.md
Project Based Examples (Legacy)
-
Homework_1_Q1_TimeSeries.ipynb
-
Homework_1_Q2_PCA.ipynb
-
Homework_1_Q3_SVM.ipynb
-
Homework_2_Q1_Tree.ipynb
-
Homework_2_Q2_RandomForest.ipynb
-
Homework_2_Q3_Bagging_with_Linear_Regression.ipynb
-
Homework_3_Q1_Logistic_Regression.ipynb
-
Homework_3_Q2_Gradient_Boosting_with_Decision_Trees.ipynb
-
Homework_3_Q3_Multilayer_Perceptron.ipynb
-
Homework_4_Q1_Vanilla_RNN.ipynb
-
Homework_4_Q2_LSTM.ipynb
-
Homework_4_Q3_Autoencoders.ipynb
Contact core developers
Please open an issue at https://github.com/dof-studio/MML if you find a bug or functionality problem.
To directly contact the developer team, send an e-mail to dof.hbx@gmail.com (can't ensure to be replied).
We welcome and value any positive contribution to this repository.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mml_pypi-0.0.5.tar.gz.
File metadata
- Download URL: mml_pypi-0.0.5.tar.gz
- Upload date:
- Size: 235.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d158ad124410525f3264c64eda5d10e17918480548e674233224dbec0126b01
|
|
| MD5 |
8cf2125092d6e238d5cca4926eb1efe5
|
|
| BLAKE2b-256 |
aefd86b34ebd167a6ab9876a25b22c3a891a2032f7e54c9bb53c895940e977cb
|
File details
Details for the file mml_pypi-0.0.5-py3-none-any.whl.
File metadata
- Download URL: mml_pypi-0.0.5-py3-none-any.whl
- Upload date:
- Size: 263.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
db52499d42bd87d04ad8bf3f031ec2bf78015c455a1dc45ad1d7a6f81a80dbae
|
|
| MD5 |
99a32e08891f4b3387ecc2a611eb4f4d
|
|
| BLAKE2b-256 |
3975fc1948016fb82915abb88ffaff2aff72ea4c26ebf7e6f31b5c67ef046c24
|