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

How apply inference on text of length less than then segment size? #9

Open
venkateshvayyavuru opened this issue Feb 4, 2021 · 3 comments

Comments

@venkateshvayyavuru
Copy link

Hi,
I have trained the model with segment size of 32. Now i want to apply the inference on unpuntucated text of length less than the segment size. I got struck here, can anyone help me for the same.

Thanks in advance,
Venkatesh

@Adam-fei
Copy link

hi, have you got the idea? I have the same problem.
Thx

@kotikkonstantin
Copy link

@venkateshvayyavuru @Adam-fei
Hi guys! I hope you are doing well! For resolving this problem, you can take a look at https://github.com/kotikkonstantin/ru-autopunctuation/blob/master/inference.py (def make_single_text_pred)

@Adam-fei
Copy link

Adam-fei commented Jul 5, 2021

@kotikkonstantin @venkateshvayyavuru
Thx a lot!
I've already solved this problem by simply repeating the text itself to meet the min infer length. And trim the output into the original text length.
It worked fine~

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

No branches or pull requests

3 participants