pytorch-openai-transformer-lm icon indicating copy to clipboard operation
pytorch-openai-transformer-lm copied to clipboard

How to use Inference?

Open masati91 opened this issue 6 years ago • 4 comments

I got an error when i try to use inference.

task_head_type == 'inference'

train.py, line 236 dh_model = DoubleHeadModel(args, clf_token, 'inference', vocab, n_ctx)

capture

20180816_131621

masati91 avatar Aug 16 '18 04:08 masati91

As mentioned in #24, the inference head have not been tested yet.

I would love to work with you on it.

Could you post a bigger piece of code showing us how you are trying to use the model?

rodgzilla avatar Aug 23 '18 10:08 rodgzilla

I'm trying to distinguish the fake news with unsupervised learning.

However, I'm having trouble with changing the weights file(e.g. params0 to params9 in your code) for Korean language.

How can I get the weights or change the files above?

masati91 avatar Aug 23 '18 10:08 masati91

The pre-trained network is only available in english for now. Multiple issues are open about this in the openAI repo (#2 and #20) but no response so far from the authors of the paper.

rodgzilla avatar Aug 23 '18 10:08 rodgzilla

How about generating the weights of Korean with Korean dataset together?

If you know the way how to pretrain the weights with English,

I'm sure that we can apply this for Korean language.

Or you can share the code for it.

masati91 avatar Aug 23 '18 11:08 masati91