<p align="center">
<a href="https://www.tinybig.org">
<img src="https://raw.githubusercontent.com/jwzhanggy/tinyBIG/main/docs/assets/img/tinybig.png" alt="function_data" style="max-width: 100%; height: auto;">
</a>
</p>
--------------------------------------------------------------------------------
### Introduction
`tinybig` is a Python library developed by the IFM Lab for deep function learning model designing and building.
* List of RPN Papers:
* RPN 1 (July 2024): https://arxiv.org/abs/2407.04819
* RPN 2 (November 2024): https://arxiv.org/abs/2411.11162
* RPN 3 (To be released ...)
* `tinybig` based Applications:
* TBD
* Official Website: https://www.tinybig.org/
* PyPI: https://pypi.org/project/tinybig/
* IFM Lab: https://www.ifmlab.org/index.html
* Project Description in Chinese:
* [RPN 1 项目中文介绍](docs/中文简介/RPN_1/README.md)
* [RPN 2 项目中文介绍](docs/中文简介/RPN_2/README.md)
### Citation
If you find `tinybig` library and RPN papers useful in your work, please cite the RPN papers as follows:
```
@article{Zhang2024RPN_version1,
title={RPN: Reconciled Polynomial Network Towards Unifying PGMs, Kernel SVMs, MLP and KAN},
author={Jiawei Zhang},
year={2024},
eprint={2407.04819},
archivePrefix={arXiv},
primaryClass={cs.LG}
}
@article{Zhang2024RPN_version2,
title={RPN 2: On Interdependence Function Learning Towards Unifying and Advancing CNN, RNN, GNN, and Transformer},
author={Jiawei Zhang},
year={2024},
eprint={2411.11162},
archivePrefix={arXiv},
primaryClass={cs.LG}
}
```
### Installation
You can install `tinybig` either via `pip` or directly from the github source code.
#### Install via Pip
```shell
pip install tinybig
```
#### Install from Source
```shell
git clone https://github.com/jwzhanggy/tinyBIG.git
```
After entering the downloaded source code directory, tinybig can be installed with the following command:
```shell
python setup.py install
```
If you don't have `setuptools` installed locally, please consider to first install `setuptools`:
```shell
pip install setuptools
```
### Install Dependency
Please download the [requirements.txt](https://github.com/jwzhanggy/tinyBIG/blob/main/requirements.txt) file, and install all the dependency packages:
```shell
pip install -r requirements.txt
```
### Verification
If you have successfully installed both `tinybig` and the dependency packages, now you can use `tinybig` in your projects.
To ensure that `tinybig` was installed correctly, we can verify the installation by running the sample python code as follows:
```python
>>> import torch
>>> import tinybig as tb
>>> expansion_func = tb.expansion.taylor_expansion()
>>> expansion_func(torch.Tensor([[1, 2]]))
```
The output should be something like:
```python
tensor([[1., 2., 1., 2., 2., 4.]])
```
### Tutorials
| Tutorial ID | Tutorial Title | Last Update |
|:-------------------------------------------------------------------------------------------:|:------------------------------------:|:-----------------:|
| [Tutorial 0](https://www.tinybig.org/guides/quick_start/) | Quickstart Tutorial | July 6, 2024 |
| [Tutorial 1](https://www.tinybig.org/tutorials/beginner/module/expansion_function/) | Data Expansion Functions | July 7, 2024 |
| [Tutorial 2](https://www.tinybig.org/tutorials/beginner/module/reconciliation_function/) | Parameter Reconciliation Functions | November 28, 2024 |
| [Tutorial 3](https://www.tinybig.org/tutorials/beginner/module/interdependence_function/) | Data Interdependence Functions | December 1, 2024 |
| [Tutorial 4](https://www.tinybig.org/tutorials/beginner/module/interdependence_function_2/) | Structural Interdependence Functions | December 10, 2024 |
### Examples
| Example ID | Example Title | Released Date |
|:---------------------------------------------------------------------:|:--------------------------------------------------:|:--------------:|
| [Example 0](https://www.tinybig.org/examples/text/kan/) | Failure of KAN on Sparse Data | July 9, 2024 |
| [Example 1](https://www.tinybig.org/examples/function/elementary/) | Elementary Function Approximation | July 7, 2024 |
| [Example 2](https://www.tinybig.org/examples/function/composite/) | Composite Function Approximation | July 8, 2024 |
| [Example 3](https://www.tinybig.org/examples/function/feynman/) | Feynman Function Approximation | July 8, 2024 |
| [Example 4](https://www.tinybig.org/examples/image/mnist/) | MNIST Classification with Identity Reconciliation | July 8, 2024 |
| [Example 5](https://www.tinybig.org/examples/image/mnist_dual_lphm/) | MNIST Classification with Dual LPHM Reconciliation | July 8, 2024 |
| [Example 6](https://www.tinybig.org/examples/image/cifar10/) | CIFAR10 Image Object Recognition | July 8, 2024 |
| [Example 7](https://www.tinybig.org/examples/text/imdb/) | IMDB Review Classification | July 9, 2024 |
| [Example 8](https://www.tinybig.org/examples/text/agnews/) | AGNews Topic Classification | July 9, 2024 |
| [Example 9](https://www.tinybig.org/examples/text/sst2/) | SST-2 Sentiment Classification | July 9, 2024 |
| [Example 10](https://www.tinybig.org/examples/tabular/iris/) | Iris Species Inference (Naive Probabilistic) | July 9, 2024 |
| [Example 11](https://www.tinybig.org/examples/tabular/diabetes/) | Diabetes Diagnosis (Comb. Probabilistic) | July 9, 2024 |
| [Example 12](https://www.tinybig.org/examples/tabular/banknote/) | Banknote Authentication (Comb. Probabilistic) | July 9, 2024 |
### Library Organizations
| Components | Descriptions |
|:-------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------|
| [`tinybig`](https://www.tinybig.org/documentations/tinybig/) | a deep function learning library like torch.nn, deeply integrated with autograd |
| [`tinybig.model`](https://www.tinybig.org/documentations/model/) | a library providing the RPN models for addressing various deep function learning tasks |
| [`tinybig.module`](https://www.tinybig.org/documentations/module/) | a library providing the basic building blocks for RPN model designing and implementation |
| [`tinybig.layer`](https://www.tinybig.org/documentations/layer/) | a library providing the implemented layers for RPN model designing and implementation |
| [`tinybig.head`](https://www.tinybig.org/documentations/head/) | a library providing the implemented heads for RPN model designing and implementation |
| [`tinybig.config`](https://www.tinybig.org/documentations/config/) | a library providing model component instantiation from textual configuration descriptions |
| [`tinybig.expansion`](https://www.tinybig.org/documentations/expansion/) | a library providing the "data expansion functions" for effective data expansions |
| [`tinybig.compression`](https://www.tinybig.org/documentations/compression/) | a library providing the "data compression functions" for effective data compression |
| [`tinybig.transformation`](https://www.tinybig.org/documentations/transformation/) | a library providing the "data transformation functions" for effective data transformation |
| [`tinybig.reconciliation`](https://www.tinybig.org/documentations/reconciliation/) | a library providing the "parameter reconciliation functions" for parameter efficient learning |
| [`tinybig.remainder`](https://www.tinybig.org/documentations/remainder/) | a library providing the "remainder functions" for complementary information addition |
| [`tinybig.interdependence`](https://www.tinybig.org/documentations/interdependence/) | a library providing the "interdependence functions" for data interdependence relationships modeling |
| [`tinybig.fusion`](https://www.tinybig.org/documentations/fusion/) | a library providing the "fusionn functions" for multi-source/channel/head data integration |
| [`tinybig.koala`](https://www.tinybig.org/documentations/koala/) | a library providing the functions from mathematics, statistics and other interdisciplinary sciences |
| [`tinybig.data`](https://www.tinybig.org/documentations/data/) | a library providing multi-modal datasets for solving various deep function learning tasks |
| [`tinybig.output`](https://www.tinybig.org/documentations/output/) | a library providing the processing method interfaces for output processing, saving and loading |
| [`tinybig.loss`](https://www.tinybig.org/documentations/loss/) | a library providing the loss functions for model introduced error computation in learning |
| [`tinybig.metric`](https://www.tinybig.org/documentations/metric/) | a library providing the metrics that can be used for model performance evaluation |
| [`tinybig.optimizer`](https://www.tinybig.org/documentations/optimizer/) | a library providing the optimizers that can be used for model parameter optimization in training |
| [`tinybig.learner`](https://www.tinybig.org/documentations/learner/) | a library providing the learner that can be used for model effective and efficient training |
| [`tinybig.visual`](https://www.tinybig.org/documentations/visual/) | a library of utility functions for data, model and learning process visualization and rendering |
| [`tinybig.util`](https://www.tinybig.org/documentations/util/) | a library of utility functions for RPN model design, implementation and learning |
| [`tinybig.zootopia`](https://www.tinybig.org/documentations/zootopia/) | a library of models developed with the functions for concrete AI applications |
### License & Copyright
Copyright © 2024 [IFM Lab](https://www.ifmlab.org/). All rights reserved.
* `tinybig` source code is published under the terms of the MIT License.
* `tinybig`'s documentation and the RPN papers are licensed under a Creative Commons Attribution-Share Alike 4.0 Unported License ([CC BY-SA 4.0](https://creativecommons.org/licenses/by-sa/4.0/)).
Raw data
{
"_id": null,
"home_page": "https://www.tinybig.org",
"name": "tinybig",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": "tinybig, rpn, deep function learning, data transformation function, data interdependence function, parameter reconciliation function, remainder function, reconciled polynomial network",
"author": "Jiawei Zhang",
"author_email": "jiawei@ifmlab.org",
"download_url": "https://files.pythonhosted.org/packages/cf/98/58a03a1d3f2976ee6570c7aff2dde2dfbd43ae6df038cd64bc4e4ccaa5c8/tinybig-0.2.1.tar.gz",
"platform": null,
"description": "<p align=\"center\">\n <a href=\"https://www.tinybig.org\">\n <img src=\"https://raw.githubusercontent.com/jwzhanggy/tinyBIG/main/docs/assets/img/tinybig.png\" alt=\"function_data\" style=\"max-width: 100%; height: auto;\">\n </a>\n</p>\n\n--------------------------------------------------------------------------------\n\n### Introduction\n\n`tinybig` is a Python library developed by the IFM Lab for deep function learning model designing and building.\n\n* List of RPN Papers: \n * RPN 1 (July 2024): https://arxiv.org/abs/2407.04819\n * RPN 2 (November 2024): https://arxiv.org/abs/2411.11162\n * RPN 3 (To be released ...)\n* `tinybig` based Applications:\n * TBD\n* Official Website: https://www.tinybig.org/\n* PyPI: https://pypi.org/project/tinybig/\n* IFM Lab: https://www.ifmlab.org/index.html\n* Project Description in Chinese: \n * [RPN 1 \u9879\u76ee\u4e2d\u6587\u4ecb\u7ecd](docs/\u4e2d\u6587\u7b80\u4ecb/RPN_1/README.md)\n * [RPN 2 \u9879\u76ee\u4e2d\u6587\u4ecb\u7ecd](docs/\u4e2d\u6587\u7b80\u4ecb/RPN_2/README.md)\n\n### Citation\n\nIf you find `tinybig` library and RPN papers useful in your work, please cite the RPN papers as follows:\n```\n@article{Zhang2024RPN_version1,\n title={RPN: Reconciled Polynomial Network Towards Unifying PGMs, Kernel SVMs, MLP and KAN},\n author={Jiawei Zhang},\n year={2024},\n eprint={2407.04819},\n archivePrefix={arXiv},\n primaryClass={cs.LG}\n}\n\n@article{Zhang2024RPN_version2,\n title={RPN 2: On Interdependence Function Learning Towards Unifying and Advancing CNN, RNN, GNN, and Transformer},\n author={Jiawei Zhang},\n year={2024},\n eprint={2411.11162},\n archivePrefix={arXiv},\n primaryClass={cs.LG}\n}\n```\n\n### Installation\n\nYou can install `tinybig` either via `pip` or directly from the github source code.\n\n#### Install via Pip\n\n```shell\npip install tinybig\n```\n\n#### Install from Source\n\n```shell\ngit clone https://github.com/jwzhanggy/tinyBIG.git\n```\n\nAfter entering the downloaded source code directory, tinybig can be installed with the following command:\n\n```shell\npython setup.py install\n```\n\nIf you don't have `setuptools` installed locally, please consider to first install `setuptools`:\n```shell\npip install setuptools \n```\n\n### Install Dependency\n\nPlease download the [requirements.txt](https://github.com/jwzhanggy/tinyBIG/blob/main/requirements.txt) file, and install all the dependency packages:\n```shell\npip install -r requirements.txt\n```\n\n### Verification\n\nIf you have successfully installed both `tinybig` and the dependency packages, now you can use `tinybig` in your projects.\n\nTo ensure that `tinybig` was installed correctly, we can verify the installation by running the sample python code as follows:\n\n```python\n>>> import torch\n>>> import tinybig as tb\n>>> expansion_func = tb.expansion.taylor_expansion()\n>>> expansion_func(torch.Tensor([[1, 2]]))\n```\nThe output should be something like:\n```python\ntensor([[1., 2., 1., 2., 2., 4.]])\n```\n\n### Tutorials\n\n| Tutorial ID | Tutorial Title | Last Update |\n|:-------------------------------------------------------------------------------------------:|:------------------------------------:|:-----------------:|\n| [Tutorial 0](https://www.tinybig.org/guides/quick_start/) | Quickstart Tutorial | July 6, 2024 |\n| [Tutorial 1](https://www.tinybig.org/tutorials/beginner/module/expansion_function/) | Data Expansion Functions | July 7, 2024 |\n| [Tutorial 2](https://www.tinybig.org/tutorials/beginner/module/reconciliation_function/) | Parameter Reconciliation Functions | November 28, 2024 |\n| [Tutorial 3](https://www.tinybig.org/tutorials/beginner/module/interdependence_function/) | Data Interdependence Functions | December 1, 2024 |\n| [Tutorial 4](https://www.tinybig.org/tutorials/beginner/module/interdependence_function_2/) | Structural Interdependence Functions | December 10, 2024 |\n\n### Examples\n\n| Example ID | Example Title | Released Date |\n|:---------------------------------------------------------------------:|:--------------------------------------------------:|:--------------:|\n| [Example 0](https://www.tinybig.org/examples/text/kan/) | Failure of KAN on Sparse Data | July 9, 2024 |\n| [Example 1](https://www.tinybig.org/examples/function/elementary/) | Elementary Function Approximation | July 7, 2024 |\n| [Example 2](https://www.tinybig.org/examples/function/composite/) | Composite Function Approximation | July 8, 2024 |\n| [Example 3](https://www.tinybig.org/examples/function/feynman/) | Feynman Function Approximation | July 8, 2024 |\n| [Example 4](https://www.tinybig.org/examples/image/mnist/) | MNIST Classification with Identity Reconciliation | July 8, 2024 |\n| [Example 5](https://www.tinybig.org/examples/image/mnist_dual_lphm/) | MNIST Classification with Dual LPHM Reconciliation | July 8, 2024 |\n| [Example 6](https://www.tinybig.org/examples/image/cifar10/) | CIFAR10 Image Object Recognition | July 8, 2024 |\n| [Example 7](https://www.tinybig.org/examples/text/imdb/) | IMDB Review Classification | July 9, 2024 |\n| [Example 8](https://www.tinybig.org/examples/text/agnews/) | AGNews Topic Classification | July 9, 2024 |\n| [Example 9](https://www.tinybig.org/examples/text/sst2/) | SST-2 Sentiment Classification | July 9, 2024 |\n| [Example 10](https://www.tinybig.org/examples/tabular/iris/) | Iris Species Inference (Naive Probabilistic) | July 9, 2024 |\n| [Example 11](https://www.tinybig.org/examples/tabular/diabetes/) | Diabetes Diagnosis (Comb. Probabilistic) | July 9, 2024 |\n| [Example 12](https://www.tinybig.org/examples/tabular/banknote/) | Banknote Authentication (Comb. Probabilistic)\t | July 9, 2024 |\n\n### Library Organizations\n\n| Components | Descriptions |\n|:-------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------|\n| [`tinybig`](https://www.tinybig.org/documentations/tinybig/) | a deep function learning library like torch.nn, deeply integrated with autograd |\n| [`tinybig.model`](https://www.tinybig.org/documentations/model/) | a library providing the RPN models for addressing various deep function learning tasks |\n| [`tinybig.module`](https://www.tinybig.org/documentations/module/) | a library providing the basic building blocks for RPN model designing and implementation |\n| [`tinybig.layer`](https://www.tinybig.org/documentations/layer/) | a library providing the implemented layers for RPN model designing and implementation |\n| [`tinybig.head`](https://www.tinybig.org/documentations/head/) | a library providing the implemented heads for RPN model designing and implementation |\n| [`tinybig.config`](https://www.tinybig.org/documentations/config/) | a library providing model component instantiation from textual configuration descriptions |\n| [`tinybig.expansion`](https://www.tinybig.org/documentations/expansion/) | a library providing the \"data expansion functions\" for effective data expansions |\n| [`tinybig.compression`](https://www.tinybig.org/documentations/compression/) | a library providing the \"data compression functions\" for effective data compression |\n| [`tinybig.transformation`](https://www.tinybig.org/documentations/transformation/) | a library providing the \"data transformation functions\" for effective data transformation |\n| [`tinybig.reconciliation`](https://www.tinybig.org/documentations/reconciliation/) | a library providing the \"parameter reconciliation functions\" for parameter efficient learning |\n| [`tinybig.remainder`](https://www.tinybig.org/documentations/remainder/) | a library providing the \"remainder functions\" for complementary information addition |\n| [`tinybig.interdependence`](https://www.tinybig.org/documentations/interdependence/) | a library providing the \"interdependence functions\" for data interdependence relationships modeling |\n| [`tinybig.fusion`](https://www.tinybig.org/documentations/fusion/) | a library providing the \"fusionn functions\" for multi-source/channel/head data integration |\n| [`tinybig.koala`](https://www.tinybig.org/documentations/koala/) | a library providing the functions from mathematics, statistics and other interdisciplinary sciences |\n| [`tinybig.data`](https://www.tinybig.org/documentations/data/) | a library providing multi-modal datasets for solving various deep function learning tasks |\n| [`tinybig.output`](https://www.tinybig.org/documentations/output/) | a library providing the processing method interfaces for output processing, saving and loading |\n| [`tinybig.loss`](https://www.tinybig.org/documentations/loss/) | a library providing the loss functions for model introduced error computation in learning |\n| [`tinybig.metric`](https://www.tinybig.org/documentations/metric/) | a library providing the metrics that can be used for model performance evaluation |\n| [`tinybig.optimizer`](https://www.tinybig.org/documentations/optimizer/) | a library providing the optimizers that can be used for model parameter optimization in training |\n| [`tinybig.learner`](https://www.tinybig.org/documentations/learner/) | a library providing the learner that can be used for model effective and efficient training |\n| [`tinybig.visual`](https://www.tinybig.org/documentations/visual/) | a library of utility functions for data, model and learning process visualization and rendering |\n| [`tinybig.util`](https://www.tinybig.org/documentations/util/) | a library of utility functions for RPN model design, implementation and learning | \n| [`tinybig.zootopia`](https://www.tinybig.org/documentations/zootopia/) | a library of models developed with the functions for concrete AI applications | \n\n\n### License & Copyright\n\nCopyright \u00a9 2024 [IFM Lab](https://www.ifmlab.org/). All rights reserved.\n\n* `tinybig` source code is published under the terms of the MIT License. \n* `tinybig`'s documentation and the RPN papers are licensed under a Creative Commons Attribution-Share Alike 4.0 Unported License ([CC BY-SA 4.0](https://creativecommons.org/licenses/by-sa/4.0/)). \n\n",
"bugtrack_url": null,
"license": "MIT License",
"summary": "tinybig library for deep function learning",
"version": "0.2.1",
"project_urls": {
"Download": "https://github.com/jwzhanggy/tinyBIG",
"Homepage": "https://www.tinybig.org"
},
"split_keywords": [
"tinybig",
" rpn",
" deep function learning",
" data transformation function",
" data interdependence function",
" parameter reconciliation function",
" remainder function",
" reconciled polynomial network"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "8446cf74bb4c9bc188b6b74f9e10761f123b5fda6f23dbb8fbcc40ae239edf13",
"md5": "bf3b5e6d1444d7f2323bafe9c2160a3f",
"sha256": "854ca4a22af333847ce21166762efc28e693f55b7c6b05ac18fabed774caad62"
},
"downloads": -1,
"filename": "tinybig-0.2.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "bf3b5e6d1444d7f2323bafe9c2160a3f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 449670,
"upload_time": "2024-12-10T09:11:21",
"upload_time_iso_8601": "2024-12-10T09:11:21.608127Z",
"url": "https://files.pythonhosted.org/packages/84/46/cf74bb4c9bc188b6b74f9e10761f123b5fda6f23dbb8fbcc40ae239edf13/tinybig-0.2.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "cf9858a03a1d3f2976ee6570c7aff2dde2dfbd43ae6df038cd64bc4e4ccaa5c8",
"md5": "d49dd838c3f5d07688c0f90d65b6a570",
"sha256": "abd5c384f4f94b6d5e013e848a66b3ce386143d25c1a401d70b810f22a32c7ed"
},
"downloads": -1,
"filename": "tinybig-0.2.1.tar.gz",
"has_sig": false,
"md5_digest": "d49dd838c3f5d07688c0f90d65b6a570",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 40811307,
"upload_time": "2024-12-10T09:11:28",
"upload_time_iso_8601": "2024-12-10T09:11:28.476580Z",
"url": "https://files.pythonhosted.org/packages/cf/98/58a03a1d3f2976ee6570c7aff2dde2dfbd43ae6df038cd64bc4e4ccaa5c8/tinybig-0.2.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-10 09:11:28",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "jwzhanggy",
"github_project": "tinyBIG",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "torch",
"specs": [
[
"==",
"2.2.2"
]
]
},
{
"name": "torchdata",
"specs": [
[
"==",
"0.7.1"
]
]
},
{
"name": "torchvision",
"specs": [
[
"==",
"0.17.2"
]
]
},
{
"name": "torchtext",
"specs": [
[
"==",
"0.17.2"
]
]
},
{
"name": "portalocker",
"specs": [
[
"==",
"2.10.0"
]
]
},
{
"name": "numpy",
"specs": [
[
"==",
"1.26.3"
]
]
},
{
"name": "scipy",
"specs": [
[
"==",
"1.13.1"
]
]
},
{
"name": "scikit-learn",
"specs": [
[
"==",
"1.5.1"
]
]
},
{
"name": "pyyaml",
"specs": [
[
"==",
"6.0.1"
]
]
},
{
"name": "tqdm",
"specs": [
[
"==",
"4.66.4"
]
]
},
{
"name": "matplotlib",
"specs": [
[
"==",
"3.9.1"
]
]
},
{
"name": "pytest",
"specs": [
[
"==",
"8.3.3"
]
]
}
],
"lcname": "tinybig"
}