tinyimagenet


Nametinyimagenet JSON
Version 0.9.9 PyPI version JSON
download
home_pagehttps://github.com/facundoq/tinyimagenet
SummaryDataset class for PyTorch and the TinyImageNet dataset, with automated download and extraction.
upload_time2023-12-26 23:06:04
maintainer
docs_urlNone
authorFacundo Manuel Quiroga
requires_python>=3.6
license
keywords tinyimagenet imagenet dataset pytorch torch torchvision
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # torchvision-tinyimagenet
Dataset class for PyTorch and the TinyImageNet dataset.

# Installation

``` pip install tinyimagenet ```

# How to use
````
from tinyimagenet import TinyImageNet
from pathlib import Path
import logging

logging.basicConfig(level=logging.INFO)

split ="val"
dataset = TinyImageNet(Path("~/.torchvision/tinyimagenet/"),split=split)
n = len(dataset)
print(f"TinyImageNet, split {split}, has  {n} samples.")
n_samples = 5
print(f"Showing info of {n_samples} samples...")
for i in range(0,n,n//n_samples):
    image,klass = dataset[i]
    print(f"Sample of class {klass:3d}, image {image}, words {dataset.idx_to_words[klass]}")
````

You can also check the [quickstart notebook](https://colab.research.google.com/drive/1FCDsDJg86mCjyeAWOxDW9iF49goWCx4j?usp=sharing) to peruse the dataset.

Finally, we also provide some example notebooks that use TinyImageNet with PyTorch models:

* [Evaluate a pretrained EfficientNet model](https://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Eval%20EfficientNet%20with%20TinyImageNet.ipynb#scrollTo=41aVk-yvEV-o)
* [Train a simple CNN on the dataset](
https://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Train%20basic%20CNN%20with%20TinyImageNet.ipynb#scrollTo=4CiA6z8reXYP)
* [Finetune an EfficientNet model pretrained on the full ImageNet to classify only the 200 classes of TinyImageNet](https://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Finetune%20EfficientNet%20with%20TinyImageNet.ipynb)



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/facundoq/tinyimagenet",
    "name": "tinyimagenet",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": "",
    "keywords": "TinyImageNet ImageNet Dataset PyTorch torch torchvision",
    "author": "Facundo Manuel Quiroga",
    "author_email": "facundoq@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/1e/79/a9284fd961664d6c23a4f85ca6ee7db82273f37d61cd7317bab83e4b223f/tinyimagenet-0.9.9.tar.gz",
    "platform": null,
    "description": "# torchvision-tinyimagenet\nDataset class for PyTorch and the TinyImageNet dataset.\n\n# Installation\n\n``` pip install tinyimagenet ```\n\n# How to use\n````\nfrom tinyimagenet import TinyImageNet\nfrom pathlib import Path\nimport logging\n\nlogging.basicConfig(level=logging.INFO)\n\nsplit =\"val\"\ndataset = TinyImageNet(Path(\"~/.torchvision/tinyimagenet/\"),split=split)\nn = len(dataset)\nprint(f\"TinyImageNet, split {split}, has  {n} samples.\")\nn_samples = 5\nprint(f\"Showing info of {n_samples} samples...\")\nfor i in range(0,n,n//n_samples):\n    image,klass = dataset[i]\n    print(f\"Sample of class {klass:3d}, image {image}, words {dataset.idx_to_words[klass]}\")\n````\n\nYou can also check the [quickstart notebook](https://colab.research.google.com/drive/1FCDsDJg86mCjyeAWOxDW9iF49goWCx4j?usp=sharing) to peruse the dataset.\n\nFinally, we also provide some example notebooks that use TinyImageNet with PyTorch models:\n\n* [Evaluate a pretrained EfficientNet model](https://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Eval%20EfficientNet%20with%20TinyImageNet.ipynb#scrollTo=41aVk-yvEV-o)\n* [Train a simple CNN on the dataset](\nhttps://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Train%20basic%20CNN%20with%20TinyImageNet.ipynb#scrollTo=4CiA6z8reXYP)\n* [Finetune an EfficientNet model pretrained on the full ImageNet to classify only the 200 classes of TinyImageNet](https://colab.research.google.com/github/facundoq/tinyimagenet/blob/main/Finetune%20EfficientNet%20with%20TinyImageNet.ipynb)\n\n\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "Dataset class for PyTorch and the TinyImageNet dataset, with automated download and extraction.",
    "version": "0.9.9",
    "project_urls": {
        "Bug Tracker": "https://github.com/facundoq/tinyimagenet/issues",
        "Documentation": "https://github.com/facundoq/tinyimagenet",
        "Homepage": "https://github.com/facundoq/tinyimagenet",
        "Source Code": "https://github.com/facundoq/tinyimagenet"
    },
    "split_keywords": [
        "tinyimagenet",
        "imagenet",
        "dataset",
        "pytorch",
        "torch",
        "torchvision"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5d0791f5937864082de49f5c32d2d79983829d38a1b911f5e0dc719e8cf16eb1",
                "md5": "d478384db7781856589d74fdf29825e0",
                "sha256": "941c7d3b19cb2f3fa719799530745a3cc0e7095a1990f2f5be107d355ec359df"
            },
            "downloads": -1,
            "filename": "tinyimagenet-0.9.9-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d478384db7781856589d74fdf29825e0",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": ">=3.6",
            "size": 9162,
            "upload_time": "2023-12-26T23:06:03",
            "upload_time_iso_8601": "2023-12-26T23:06:03.042122Z",
            "url": "https://files.pythonhosted.org/packages/5d/07/91f5937864082de49f5c32d2d79983829d38a1b911f5e0dc719e8cf16eb1/tinyimagenet-0.9.9-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1e79a9284fd961664d6c23a4f85ca6ee7db82273f37d61cd7317bab83e4b223f",
                "md5": "90dd492af4bcc614cca0da96ead70b83",
                "sha256": "bcbd21749abc63138fedf213501fd509c3e8495f2e78b8af5492338f876cc07a"
            },
            "downloads": -1,
            "filename": "tinyimagenet-0.9.9.tar.gz",
            "has_sig": false,
            "md5_digest": "90dd492af4bcc614cca0da96ead70b83",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 11323,
            "upload_time": "2023-12-26T23:06:04",
            "upload_time_iso_8601": "2023-12-26T23:06:04.639950Z",
            "url": "https://files.pythonhosted.org/packages/1e/79/a9284fd961664d6c23a4f85ca6ee7db82273f37d61cd7317bab83e4b223f/tinyimagenet-0.9.9.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-12-26 23:06:04",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "facundoq",
    "github_project": "tinyimagenet",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "tinyimagenet"
}
        
Elapsed time: 0.37424s