NVIDIA / DeepLearningExamples

State-of-the-Art Deep Learning scripts organized by models - easy to train and deploy with reproducible accuracy and performance on enterprise-grade infrastructure.
13.6k stars 3.24k forks source link

[FastPitch 1.1] - ONNX for Hifi Gan and Fast Pitch #1125

Open ArEnSc opened 2 years ago

ArEnSc commented 2 years ago

@GrzegorzKarchNV @alancucki

Hey I am looking to convert Fast Pitch and HiFi Gan to ONNX mainly because PyTorch is a huge dependency and I need this packaged more efficiently.

Are there any challenges you anticipate to exporting fast pitch to ONNX along side with hifi gan? I am looking at the PyTorch tutorial, it seems straight forward.

Will this appear on the road map eventually?

Thanks.

Describe the solution you'd like Have scripts to run to export the ONNX Hifi Gan and Fast Pitch Models.

ArEnSc commented 2 years ago

So I looked in this a bit. It seems like a limitation for the forward infer function is that it takes in a pitch transform function could could it be rewritten to work with this? my guess is, it wouldn't be possible for onnx.

ArEnSc commented 2 years ago

Okay so I would guess, that we could have the pitch transforms working if we break each prediction network into onnx models and then execute inference over each model. It would kill the dependency of having PyTorch available and possibly boost inference speed at the cost of managing more models.