simplepe


Namesimplepe JSON
Version 0.0.1 PyPI version JSON
download
home_pagehttps://github.com/donglinkang2021/simplepe
SummaryA simple simplepe for positional encoding
upload_time2024-12-22 15:39:01
maintainerNone
docs_urlNone
authorDong Linkang
requires_pythonNone
licenseNone
keywords artificial intelligence deep learning positional embedding
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # SimplePE

Simple implementation of some Positional Encoding methods in PyTorch.

- [x] Sinusoidal Positional Encoding
- [x] Rotary Positional Encoding

## Installation

```bash
git clone https://github.com/donglinkang2021/simplepe.git
cd simplepe
pip install .
```

## Usage

```python
python example.py # Run the example
```

You can see the following results:

| Method | Sinusoidal | Rotary |
| ------------ | ---------- | ------ |
| Dimension-Time_Step Heatmap | ![Sinusoidal](./images/Sinusoidal_Positional_Encoding_Heatmap.png) | ![Rotary](./images/Rotary_Positional_Encoding_Heatmap.png) |
| Value-Time_Step Line_Plot | ![Sinusoidal](./images/Sinusoidal_Positional_Encoding_LinePlot.png) | ![Rotary](./images/Rotary_Positional_Encoding_LinePlot.png) |
| Multi-Head Dimension-Time_Step Heatmap | ![Sinusoidal](./images/Multi-Head_Sinusoidal_Positional_Encoding_Heatmap.png) | ![Rotary](./images/Multi-Head_Rotary_Positional_Encoding_Heatmap.png) |
| Multi-Head Value-Time_Step Line_Plot | ![Sinusoidal](./images/Multi-Head_Sinusoidal_Positional_Encoding_LinePlot.png) | ![Rotary](./images/Multi-Head_Rotary_Positional_Encoding_LinePlot.png) |



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/donglinkang2021/simplepe",
    "name": "simplepe",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "artificial intelligence, deep learning, positional embedding",
    "author": "Dong Linkang",
    "author_email": "donglinkang2021@163.com",
    "download_url": "https://files.pythonhosted.org/packages/33/04/75d60a23e97d61dbe87ded5c58b0c4b4e2f758ad14e2aa677791e2ec78c7/simplepe-0.0.1.tar.gz",
    "platform": null,
    "description": "# SimplePE\n\nSimple implementation of some Positional Encoding methods in PyTorch.\n\n- [x] Sinusoidal Positional Encoding\n- [x] Rotary Positional Encoding\n\n## Installation\n\n```bash\ngit clone https://github.com/donglinkang2021/simplepe.git\ncd simplepe\npip install .\n```\n\n## Usage\n\n```python\npython example.py # Run the example\n```\n\nYou can see the following results:\n\n| Method | Sinusoidal | Rotary |\n| ------------ | ---------- | ------ |\n| Dimension-Time_Step Heatmap | ![Sinusoidal](./images/Sinusoidal_Positional_Encoding_Heatmap.png) | ![Rotary](./images/Rotary_Positional_Encoding_Heatmap.png) |\n| Value-Time_Step Line_Plot | ![Sinusoidal](./images/Sinusoidal_Positional_Encoding_LinePlot.png) | ![Rotary](./images/Rotary_Positional_Encoding_LinePlot.png) |\n| Multi-Head Dimension-Time_Step Heatmap | ![Sinusoidal](./images/Multi-Head_Sinusoidal_Positional_Encoding_Heatmap.png) | ![Rotary](./images/Multi-Head_Rotary_Positional_Encoding_Heatmap.png) |\n| Multi-Head Value-Time_Step Line_Plot | ![Sinusoidal](./images/Multi-Head_Sinusoidal_Positional_Encoding_LinePlot.png) | ![Rotary](./images/Multi-Head_Rotary_Positional_Encoding_LinePlot.png) |\n\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A simple simplepe for positional encoding",
    "version": "0.0.1",
    "project_urls": {
        "Homepage": "https://github.com/donglinkang2021/simplepe"
    },
    "split_keywords": [
        "artificial intelligence",
        " deep learning",
        " positional embedding"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3e91c3e1cb58751058439abdae30287758afe0346627cfc6f3a630af5389032f",
                "md5": "afed8ccc9127fd4a6096b4ef8bb5288b",
                "sha256": "c3ed5243456973b4a0ee1ee5171aad3199557a1c61caff8fec9136ec9d2bebc5"
            },
            "downloads": -1,
            "filename": "simplepe-0.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "afed8ccc9127fd4a6096b4ef8bb5288b",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 3958,
            "upload_time": "2024-12-22T15:38:58",
            "upload_time_iso_8601": "2024-12-22T15:38:58.622806Z",
            "url": "https://files.pythonhosted.org/packages/3e/91/c3e1cb58751058439abdae30287758afe0346627cfc6f3a630af5389032f/simplepe-0.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "330475d60a23e97d61dbe87ded5c58b0c4b4e2f758ad14e2aa677791e2ec78c7",
                "md5": "91c7970aa6d0c75a02fba682769503b8",
                "sha256": "2dcbea607ffec71245cec86c07a51d52a70d1fb5ae21c099c58980ed6ec810f8"
            },
            "downloads": -1,
            "filename": "simplepe-0.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "91c7970aa6d0c75a02fba682769503b8",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3450,
            "upload_time": "2024-12-22T15:39:01",
            "upload_time_iso_8601": "2024-12-22T15:39:01.139183Z",
            "url": "https://files.pythonhosted.org/packages/33/04/75d60a23e97d61dbe87ded5c58b0c4b4e2f758ad14e2aa677791e2ec78c7/simplepe-0.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-12-22 15:39:01",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "donglinkang2021",
    "github_project": "simplepe",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "simplepe"
}
        
Elapsed time: 0.39839s