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

Issue using the code #1

Closed
bentoo opened this issue Feb 26, 2022 · 1 comment
Closed

Issue using the code #1

bentoo opened this issue Feb 26, 2022 · 1 comment

Comments

@bentoo
Copy link

bentoo commented Feb 26, 2022

I am trying to use your code.

var encoded = tokenizer.Encode(32, sentence);
var result = model.Transform(encoded);
var bertInput = new ModelInput()
{
InputIds = encoded.InputIds, // this does not compile because encoded is a list of tuples
AttentionMask = encoded.AttentionMask,
TokenTypeIds = encoded.TokenTypeIds,
};

Can you provide a complete working example using ML.NET and your BertTokenizers?

@NMZivkovic
Copy link
Owner

Hi bentoo,

Thanks for the report.
The example is updated.

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

2 participants