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

Dali backend support feature to handle init function #128

Open
farzanehnakhaee70 opened this issue Apr 23, 2022 · 4 comments
Open

Dali backend support feature to handle init function #128

farzanehnakhaee70 opened this issue Apr 23, 2022 · 4 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@farzanehnakhaee70
Copy link

Is your feature request related to a problem? Please describe.
Currently dali_backend just works with post and preprocessing for the functions which do not requires initialization. What if when the init part takes longer time? Is there any solution for this?

@Tabrizian Tabrizian transferred this issue from triton-inference-server/server Apr 25, 2022
@Tabrizian
Copy link
Member

cc @szalpal @jantonguirao

@JanuszL
Copy link
Collaborator

JanuszL commented Apr 25, 2022

Hi @farzanehnakhaee70,

Could you tell us more about what do you mean by:

Currently dali_backend just works with post and preprocessing for the functions which do not require initialization

In the case of DALI if you load the processing model all the necessary operators' initialization happens. In most cases, it is just the memory allocation. Do you have any particular operation in mind which may require extended initialization?

@JanuszL JanuszL added the help wanted Extra attention is needed label Apr 25, 2022
@farzanehnakhaee70
Copy link
Author

Hi @JanuszL ,
Thanks a lot for your answer.
The problem for my side is I'm wondering if I can use dali backend for transformer like models and import the tokenizer in the initialization part and afterward use the initialized tokenizer during the processing (as it takes time for initializing the tokenizers during each execution). Is it possible?

@JanuszL
Copy link
Collaborator

JanuszL commented Apr 26, 2022

Hi @farzanehnakhaee70,

DALI is initialized once when the model is loaded. Then when the inference request is processed the pipeline is just run,
However I'm not sure if DALI is capable of tokenization. You may consider writing a custom plugin for DALI https://github.com/triton-inference-server/dali_backend/blob/main/docs/examples/dali_plugin/README.md.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Development

No branches or pull requests

4 participants