# TME
Python implementation of Tensor Maximum Entropy (TME)
Install:
```
pip install tensor-maximum-entropy
```
Usage example:
```
import numpy as np
import scipy.io
from tensor_maximum_entropy import TME
model_dim = 10
data = scipy.io.loadmat('./exampleData.mat')
dataTensor = data['dataTensor']
print(dataTensor.shape)
t = data['t']
mask = np.logical_and(t > - 50, t < 350)
TME(dataTensor, mask, model_dim)
```
The algorithm description can be found in the following article:
```
Elsayed, G.F.; Cunningham, J.P. Structure in Neural Population Recordings: An Expected Byproduct of Simpler Phenomena? Nat Neurosci 2017, 20, 1310–1318, doi:10.1038/nn.4617.
```
A matlab implementation can be found at the following link:
https://github.com/gamaleldin/TME
Raw data
{
"_id": null,
"home_page": "https://github.com/ArdeleanRichard/TME",
"name": "tensor-maximum-entropy",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": null,
"author": "Eugen-Richard Ardelean",
"author_email": "ardeleaneugenrichard@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/a6/f4/66debba698d272616597adeeffa189dae5ebe489ea306fc112094de34ec4/tensor_maximum_entropy-0.0.2.tar.gz",
"platform": null,
"description": "# TME\r\nPython implementation of Tensor Maximum Entropy (TME)\r\n\r\nInstall:\r\n```\r\npip install tensor-maximum-entropy\r\n```\r\n\r\nUsage example:\r\n```\r\nimport numpy as np\r\nimport scipy.io\r\nfrom tensor_maximum_entropy import TME\r\n\r\nmodel_dim = 10\r\n\r\ndata = scipy.io.loadmat('./exampleData.mat')\r\ndataTensor = data['dataTensor']\r\n\r\nprint(dataTensor.shape)\r\nt = data['t']\r\n\r\nmask = np.logical_and(t > - 50, t < 350)\r\nTME(dataTensor, mask, model_dim)\r\n```\r\n\r\nThe algorithm description can be found in the following article:\r\n```\r\nElsayed, G.F.; Cunningham, J.P. Structure in Neural Population Recordings: An Expected Byproduct of Simpler Phenomena? Nat Neurosci 2017, 20, 1310\u00e2\u20ac\u201c1318, doi:10.1038/nn.4617.\r\n```\r\n\r\nA matlab implementation can be found at the following link:\r\nhttps://github.com/gamaleldin/TME\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Python implementation of the Tensor Maximum Entropy (TME)",
"version": "0.0.2",
"project_urls": {
"Homepage": "https://github.com/ArdeleanRichard/TME"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "af6067b76eb65f5e7b23e10015f16caaf946066abd7f081aca939d5f3bdd8e7f",
"md5": "e2ce970cb7a65359e346c5d486b12c64",
"sha256": "deb27f1b3c6a41172f4ef38b9490fff22e162bafcd43c992f699f55aaf20d027"
},
"downloads": -1,
"filename": "tensor_maximum_entropy-0.0.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e2ce970cb7a65359e346c5d486b12c64",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 8729,
"upload_time": "2024-05-08T05:44:51",
"upload_time_iso_8601": "2024-05-08T05:44:51.147461Z",
"url": "https://files.pythonhosted.org/packages/af/60/67b76eb65f5e7b23e10015f16caaf946066abd7f081aca939d5f3bdd8e7f/tensor_maximum_entropy-0.0.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a6f466debba698d272616597adeeffa189dae5ebe489ea306fc112094de34ec4",
"md5": "0c2f2539f52b0e07b820cfaa58553164",
"sha256": "538baaf9779112bf6a04eadc20ca08c9fc1e32938265ecc91515c10cb834d76c"
},
"downloads": -1,
"filename": "tensor_maximum_entropy-0.0.2.tar.gz",
"has_sig": false,
"md5_digest": "0c2f2539f52b0e07b820cfaa58553164",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 7199,
"upload_time": "2024-05-08T05:44:53",
"upload_time_iso_8601": "2024-05-08T05:44:53.671634Z",
"url": "https://files.pythonhosted.org/packages/a6/f4/66debba698d272616597adeeffa189dae5ebe489ea306fc112094de34ec4/tensor_maximum_entropy-0.0.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-08 05:44:53",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ArdeleanRichard",
"github_project": "TME",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "numpy",
"specs": []
},
{
"name": "matplotlib",
"specs": []
},
{
"name": "scipy",
"specs": []
},
{
"name": "scikit-learn",
"specs": []
}
],
"lcname": "tensor-maximum-entropy"
}