Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC][Frontend] Add a PaddlePaddle Frontend #19

Merged
merged 11 commits into from
Aug 13, 2021

Conversation

jiangjiajun
Copy link
Contributor

Add a PaddlePaddle frontend for TVM, also I have created a RFC topic in forum where we can discuss at same time.
The related pull request is apache/tvm#8645, still lack of UT, which will be finished in a week.

@tqchen @FrozenGene @junrushao1994 @jcf94

```
import paddle
import paddlehub
model = hub.Module(name="resnet50_vd_imagenet_ssld")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we add another one script example showing how to load one paddlepaddle model from disk?

paddle.jit.save(model, "model/infer", input_spec=[input_spec])
```

PaddlePaddle's deployment is supported by Paddle Inference/Paddle Lite/OpenVINO/Tengine/Adlik now. We have noticed there are lots of developers convmodel to ONNX format for TVM's supporting, but only part of models can be converted due to the lack of ONNX operators.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

convmodel -> converting model; for TVM's supporting ---> supported by TVM

```

PaddlePaddle's deployment is supported by Paddle Inference/Paddle Lite/OpenVINO/Tengine/Adlik now. We have noticed there are lots of developers convmodel to ONNX format for TVM's supporting, but only part of models can be converted due to the lack of ONNX operators.
Based on this background, we proposed this RFC addle frontend for TVM, improve usability and extend more models support for PaddlePaddle's users.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addle-> to add paddlepaddle; improve -> to improve; extend -> to extend

mod, params = relay.frontend.from_paddle(model, shape_dict=shape_dict)
```

Error may happened if there are some operators is not supported by this frontend, and the details will print out.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Errors maybe happened; some operators is -> some operators are

@FrozenGene
Copy link
Member

@jiangjiajun Thanks for bringing this rfc, which will help TVM to serve more conveniently for paddlepaddle users. This rfc is good generally speaking. However, there are many spell grammar error so that I suggest you could do one round of proof-reading

@jiangjiajun
Copy link
Contributor Author

@jiangjiajun Thanks for bringing this rfc, which will help TVM to serve more conveniently for paddlepaddle users. This rfc is good generally speaking. However, there are many spell grammar error so that I suggest you could do one round of proof-reading

Thanks for your comments, I'll review the RFC this week and update this pull request~

@tqchen
Copy link
Member

tqchen commented Aug 9, 2021

cc @mbrookhart who works with paddle before

@jiangjiajun
Copy link
Contributor Author

Thanks @will-jl944 for revising and polishing this document, it really helps me a lot!

@FrozenGene And an example code is provided in Guide-level explanation, could you review this RFC again, thanks~

@FrozenGene FrozenGene merged commit fc5d5ed into apache:main Aug 13, 2021
@FrozenGene
Copy link
Member

@jiangjiajun Please go ahead to handle pr.

@tqchen
Copy link
Member

tqchen commented Aug 13, 2021

@FrozenGene @jiangjiajun please update the file to reflect the RFC number as in other RFCs, please also create a tracking issue per the RFC procedure

@tqchen
Copy link
Member

tqchen commented Aug 13, 2021

Two followup actionable items per https://github.com/apache/tvm-rfcs#rfc-workflow

  • Please rename the rfc to the original PR number (19)
  • Please create a tracking issue per guideline

@jiangjiajun
Copy link
Contributor Author

Two followup actionable items per https://github.com/apache/tvm-rfcs#rfc-workflow

  • Please rename the rfc to the original PR number (19)
  • Please create a tracking issue per guideline

Okay

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants