GithubHelp home page GithubHelp logo

thu-pacman / pet Goto Github PK

View Code? Open in Web Editor NEW
112.0 112.0 9.0 1.93 MB

PET: Optimizing Tensor Programs with Partially Equivalent Transformations and Automated Corrections

License: Apache License 2.0

CMake 0.45% C++ 59.77% Python 19.35% C 0.43% Cuda 18.92% Makefile 0.08% Shell 0.79% JavaScript 0.01% Cython 0.19%

pet's People

Contributors

whjthu avatar zhengly123 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pet's Issues

bert 无法跑通

在 NVIDIA GPU 环境下克隆此工程并编译运行。

首先使用 PET_DCU/benchmark/models/scripts/bert_onnx.py 导出了bert的onnx文件,然后编译了DCU之后在build下执行:

./onnx_origin ../benchmark/models/scripts/mybert-new.onnx

此时会尝试导入ONNX到PET的Graph中,这个时候发生了报错:

onnx_origin: /home/PET_DCU/include/operator.h:1795: tpm::ReshapeOp::ReshapeOp(tpm::Tensor *, tpm::Tensor *): Assertion `input->size() == output->size()' failed.
Aborted (core dumped)

可以看到挂在Reshape Op的形状检查,我打印了一下input->size()output->size() ,分别为:

589824 37748736

所以输出Tensor的size是输入的64倍,这个64是导出ONNX时的batch_size,希望可以解答这个错误的原因是什么

Understanding the generator

Hello,

I am trying to understand the generator as in the PET paper.

To my understanding, the threshold parameter in the Generator::run() function defines the number of random test point that a legal mutant has to satisfy, as computed by the Generator::approx_equal() function.

The default threshold=0.7 results in, for example, sometimes a Matmul has 20 mutants, and sometimes has 28 mutants. Is this randomness intended?

If a legal mutant passes this test, how does the correction kernel generated? Is the correction kernel generated by the Generator?

Many Thanks,

Usage Problem

Hello, I'm trying to PET, but when I configure according to the usage document, the "onnx" folder under "build" is not automatically generated. What should I do? And how do I use PET in Python?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.