pytorch模型、数据集国内镜像
Project description
PyTorch模型、数据集国内镜像
一、使用方法
只需要在使用模型或数据集之前导入torch_model_mirror
或torch_dataset_mirror
模块即可,如下:
import torch
import torch_dataset_mirror
import torch_model_mirror
import torchvision.datasets.mnist as mnist
train_dataset = mnist.MNIST("./data", train=True, download=True)
test_dataset = mnist.MNIST("./data", train=False, download=True)
二、使用其他镜像
要使用其他镜像,只需要修改PYTORCH_MODEL_MIRROR
或PYTORCH_DATASET_MIRROR
环境变量即可,如下:
export PYTORCH_MODEL_MIRROR=http://192.168.0.100:8080
export PYTORCH_DATASET_MIRROR=http://192.168.0.100:8080
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pytorch_mirror-0.4.1.tar.gz
(4.3 kB
view details)
Built Distribution
File details
Details for the file pytorch_mirror-0.4.1.tar.gz
.
File metadata
- Download URL: pytorch_mirror-0.4.1.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3.post20200330 requests-toolbelt/0.9.1 tqdm/4.44.1 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 03c9870b4d79ab01829c76abf7a0a781ca7c190500fa07ec49e657f4413d9cc1 |
|
MD5 | 043508286b85bf2f49b9123f5b85e912 |
|
BLAKE2b-256 | fdc2c24093c3d4f384e73fd59b7fb449c8343f8ce374cb2f8ef5fb8b19652e6d |
File details
Details for the file pytorch_mirror-0.4.1-py3-none-any.whl
.
File metadata
- Download URL: pytorch_mirror-0.4.1-py3-none-any.whl
- Upload date:
- Size: 8.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3.post20200330 requests-toolbelt/0.9.1 tqdm/4.44.1 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e5c396e43a6e245bb155770ba3140233516200a673aa5830339d2a2c4f524a74 |
|
MD5 | 90e5ed0745e82e747fe4607140de4018 |
|
BLAKE2b-256 | 7ba6e7c472cc8657c7821b4a2197a43873d7e00afa50dafcf4df9b527c540c82 |