Skip to main content

A toolbox about DNN Reliability

Project description

torchei_logo

TorchEI⚡

IntroUsageDocCiteContributionLicense

Introduction

👋TorchEI, pronouced /ˈtôrCHər/, short for Pytorch Error Injection, is a high-speed toolbox around DNN Reliability's Research and Development. TorchEI enables you quickly and simply inject errors into DNN, collects information you needed, and harden your DNN.

TorchEI implemented incredible parallel evaluation system which could allow you adequately utilize device computing performance with tolerance to non-catastrophic faults.

Features

  • Full typing system supported
  • Contains methods from papers in DNN Reliability
  • High-efficiency, fault-tolerant parallel system

Quick Example

Here we gonna show you a quick example, or you can try interactive demo and online edtior.

Installing

Install public distribution using pip3 install torchei or download it.

Example

Init fault model

import torch
from torchvision import models
import torchei
model = models.resnet18(pretrained=True)
data = torch.load('./datasets/ilsvrc_valid8.pt')
fault_model = torchei.fault_model(model,data)

Calc reliability using emat method

fault_model.emat_attack(10,1e-3)

Calc reliability using Parallel Mechanism (under developing)


Calc reliability using SERN

fault_model.sern_calc(output_class=1000)

Harden DNN by ODR

fault_model.outlierDR_protection()
fault_model.emat_attack(10,1e-3)

Contribution

If you found🧐 any bugs or have🖐️ any suggestions, please tell us.

This repo is open to everyone wants to maintain together.

You can helps us with follow things:

  • PR your implemented methods in your or others' papers
  • Complete our project
  • Translate our docs to your language
  • Other

We want to build TorchEI to best toolbox in DNN Reliability around bit flip, adversarial attack, and others. :e-mail: forcessless@foxmail.com

Citation

Our paper is under reviewing.

License

MIT License. Copyright:copyright:2022/5/23-present, Hao Zheng.

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

torchei-0.0.6.tar.gz (2.9 MB view details)

Uploaded Source

Built Distributions

torchei-0.0.6-py3-none-any.whl (10.5 kB view details)

Uploaded Python 3

torchei-0.0.6-1-py3-none-any.whl (10.6 kB view details)

Uploaded Python 3

File details

Details for the file torchei-0.0.6.tar.gz.

File metadata

  • Download URL: torchei-0.0.6.tar.gz
  • Upload date:
  • Size: 2.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for torchei-0.0.6.tar.gz
Algorithm Hash digest
SHA256 4c8c26e2a52c745f8cf8ec3e17f8be54dc1c1c3366aad9155a41332ea4ccacbf
MD5 fd75435904db14459da576fd7ff6b3a9
BLAKE2b-256 b368b1bfe6c00dee7b929d75f673504efa6dfa411fa4f08b7a3cfb0e8d76ed99

See more details on using hashes here.

File details

Details for the file torchei-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: torchei-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 10.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for torchei-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 c485329388b297b8e043d74ffee1ec8368d8c3cc0bfb0707211be9dcb5f0e94f
MD5 eae41c6dcc3d860879c3365f61691378
BLAKE2b-256 cfe98c087cd4bf60b892e4e1d496e284bc9369f171d0e510172f046dbb5107ae

See more details on using hashes here.

File details

Details for the file torchei-0.0.6-1-py3-none-any.whl.

File metadata

  • Download URL: torchei-0.0.6-1-py3-none-any.whl
  • Upload date:
  • Size: 10.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for torchei-0.0.6-1-py3-none-any.whl
Algorithm Hash digest
SHA256 5ba3a0be474e8a57e71b4675d39a4e3af2543f3de9120fb757d726ebb34709f0
MD5 ce2e680b35ebe9fe8334762444366641
BLAKE2b-256 c8d592f9cfb9d0274bb41cfa028a03be7963701f27add70978750b1df7650cf3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page