eeg-dementia-classification-MNet


Nameeeg-dementia-classification-MNet JSON
Version 1.4.0 PyPI version JSON
download
home_pagehttps://github.com/yanagisawa-lab/eeg-dementia-classification
SummaryPretrained MNet model for classifying demetia subclasses (HV, AD, DLB, and iNPH)
upload_time2023-12-23 08:58:56
maintainer
docs_urlNone
authorywatanabe1989
requires_python>=3.0
licenseMIT
keywords dementia screening mild cognitive impairment alzheimer's disease ad dementia with lewy bodies dlb idiopathic normal-pressure hydrocephalus inph multiple centres
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ## Installation
``` bash
$ pip install eeg-dementia-classification-MNet
```

## Pretrained Weights
Pretrained weights are available on [our Google Drive](https://drive.google.com/file/d/1QZYlEtcd4Szf5K55cNrSxalHcW6UjkaF/view?usp=sharing).
1. Download 'pretrained_weights.tar.gz'.
2. Extract the file using the following command:
``` bash
$ tar xvf pretrained_weights.tar.gz
```
3. Locate the extradcted 'pretrained_weights' directory at the working directory. As an illustration, the weight files (.pth) should be organized as follows:
```
./pretrained_weights/
├── AD_vs_DLB
│   ├── model_fold#0_epoch#045.pth
│   ├── model_fold#1_epoch#031.pth
│   ├── model_fold#2_epoch#029.pth
│   ├── model_fold#3_epoch#031.pth
│   └── model_fold#4_epoch#028.pth
├── AD_vs_DLB_vs_NPH
│   ├── model_fold#0_epoch#024.pth
│   ├── model_fold#1_epoch#035.pth
...
```

## Usage
``` python
from eeg_dementia_classification_MNet import MNet_1000
import torch

## Parameters
DISEASE_TYPES = ["HV", "AD", "DLB", "NPH"]

## MNet
model = MNet_1000(DISEASE_TYPES, is_ensemble=True)
model.load_weights(i_fold=0)

## Feeds data
bs, n_chs, seq_len = 16, 19, 1000
x = torch.rand(bs, n_chs, seq_len)
y = model(x)
```

## Contact
Please feel free to contact [the author](mailto:ywata1989@gmail.com).

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/yanagisawa-lab/eeg-dementia-classification",
    "name": "eeg-dementia-classification-MNet",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.0",
    "maintainer_email": "",
    "keywords": "dementia screening,mild cognitive impairment,Alzheimer's disease,AD,dementia with Lewy bodies,DLB,idiopathic normal-pressure hydrocephalus,iNPH,multiple centres",
    "author": "ywatanabe1989",
    "author_email": "ywata1989@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/f8/99/d67f50fa8d5129bd987469c871da4db092b7e442ac221adedd5905c6fcdf/eeg_dementia_classification_MNet-1.4.0.tar.gz",
    "platform": null,
    "description": "## Installation\n``` bash\n$ pip install eeg-dementia-classification-MNet\n```\n\n## Pretrained Weights\nPretrained weights are available on [our Google Drive](https://drive.google.com/file/d/1QZYlEtcd4Szf5K55cNrSxalHcW6UjkaF/view?usp=sharing).\n1. Download 'pretrained_weights.tar.gz'.\n2. Extract the file using the following command:\n``` bash\n$ tar xvf pretrained_weights.tar.gz\n```\n3. Locate the extradcted 'pretrained_weights' directory at the working directory. As an illustration, the weight files (.pth) should be organized as follows:\n```\n./pretrained_weights/\n\u251c\u2500\u2500 AD_vs_DLB\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#0_epoch#045.pth\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#1_epoch#031.pth\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#2_epoch#029.pth\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#3_epoch#031.pth\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 model_fold#4_epoch#028.pth\n\u251c\u2500\u2500 AD_vs_DLB_vs_NPH\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#0_epoch#024.pth\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 model_fold#1_epoch#035.pth\n...\n```\n\n## Usage\n``` python\nfrom eeg_dementia_classification_MNet import MNet_1000\nimport torch\n\n## Parameters\nDISEASE_TYPES = [\"HV\", \"AD\", \"DLB\", \"NPH\"]\n\n## MNet\nmodel = MNet_1000(DISEASE_TYPES, is_ensemble=True)\nmodel.load_weights(i_fold=0)\n\n## Feeds data\nbs, n_chs, seq_len = 16, 19, 1000\nx = torch.rand(bs, n_chs, seq_len)\ny = model(x)\n```\n\n## Contact\nPlease feel free to contact [the author](mailto:ywata1989@gmail.com).\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Pretrained MNet model for classifying demetia subclasses (HV, AD, DLB, and iNPH)",
    "version": "1.4.0",
    "project_urls": {
        "Homepage": "https://github.com/yanagisawa-lab/eeg-dementia-classification"
    },
    "split_keywords": [
        "dementia screening",
        "mild cognitive impairment",
        "alzheimer's disease",
        "ad",
        "dementia with lewy bodies",
        "dlb",
        "idiopathic normal-pressure hydrocephalus",
        "inph",
        "multiple centres"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1424ddbc01190663afa45b46759e281f9cb05d6cc2fea3bf77b51f85f9f5babc",
                "md5": "0677165feb8552700a7a0d1c9695357b",
                "sha256": "cb3142fdacf4ccfcf7e1a58755972d2e187da8342212438a7aa859414a6b3f3d"
            },
            "downloads": -1,
            "filename": "eeg_dementia_classification_MNet-1.4.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "0677165feb8552700a7a0d1c9695357b",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.0",
            "size": 8100,
            "upload_time": "2023-12-23T08:58:54",
            "upload_time_iso_8601": "2023-12-23T08:58:54.366516Z",
            "url": "https://files.pythonhosted.org/packages/14/24/ddbc01190663afa45b46759e281f9cb05d6cc2fea3bf77b51f85f9f5babc/eeg_dementia_classification_MNet-1.4.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f899d67f50fa8d5129bd987469c871da4db092b7e442ac221adedd5905c6fcdf",
                "md5": "6c47867b61a6694109eda853fe194b84",
                "sha256": "8acc2f1222a2c3e11ddfc549d27ad47eaf15b523f3f07bab11b868802846640e"
            },
            "downloads": -1,
            "filename": "eeg_dementia_classification_MNet-1.4.0.tar.gz",
            "has_sig": false,
            "md5_digest": "6c47867b61a6694109eda853fe194b84",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.0",
            "size": 6588,
            "upload_time": "2023-12-23T08:58:56",
            "upload_time_iso_8601": "2023-12-23T08:58:56.237504Z",
            "url": "https://files.pythonhosted.org/packages/f8/99/d67f50fa8d5129bd987469c871da4db092b7e442ac221adedd5905c6fcdf/eeg_dementia_classification_MNet-1.4.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-12-23 08:58:56",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "yanagisawa-lab",
    "github_project": "eeg-dementia-classification",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "eeg-dementia-classification-mnet"
}
        
Elapsed time: 0.17760s