GithubHelp home page GithubHelp logo

Lample and Xuezhe about lm-lstm-crf HOT 6 OPEN

liyuanlucasliu avatar liyuanlucasliu commented on May 26, 2024
Lample and Xuezhe

from lm-lstm-crf.

Comments (6)

LiyuanLucasLiu avatar LiyuanLucasLiu commented on May 26, 2024

Hi,
Several days ago, we reimplemented Lample's and Xuezhe's study, and our implementations achieve roughly the same performance with their reported score (although slightly worse than Xuezhe). However, we're currently fully occupied by some potential paper submissions and dont have time to clean up and release our codes. I guess I can find some time to release those codes in 20 days.
And for your own implementation, i'm not sure why you cannot replicate...
I would let this issue open, and after i released the code, i would let you know.
Good luck and hope i can help you :-)

from lm-lstm-crf.

cosmozhang avatar cosmozhang commented on May 26, 2024

Thank you. I mean by the code you guys provided. I did not reimplement them in pytorch. :)
Good luck!

from lm-lstm-crf.

cosmozhang avatar cosmozhang commented on May 26, 2024

Hi, can I ask what is the intuition behind the function construct_bucket_vb for the labels in util.py?
More specifically, what is this line for? buckets[idx][1].append([label[ind] * label_size + label[ind + 1] for ind in range(0, cur_len)] + [label[cur_len] * label_size + pad_label] + [pad_label * label_size + pad_label] * (thresholds[idx] - cur_len_1))
Thanks!

from lm-lstm-crf.

LiyuanLucasLiu avatar LiyuanLucasLiu commented on May 26, 2024

This line is used for label padding, specifically, label padding for CRF (with bucket).
CRF models the transition of states instead of states themselves.
E.g., in Eqs. 1 of our paper, the potential function is calculated based on a (y_{i-1}, y_i) pair.
Here, we try to encode this pair into a single number (label[ind] * label_size + label[ind + 1]).
For other parts of this line, they are just doing padding.

from lm-lstm-crf.

jiesutd avatar jiesutd commented on May 26, 2024

Hi @cosmozhang , I have implemented both Lample and Xuezhe Ma's structure using PyTorch PyTorchSeqLabel .

The results are comparable with both of them, all the results are listed and compared in the repository.

The CoNLL03 English NER data is not well generalized, which means there is a big difference between dev and test data. The F1-measure in the test data is not quite stable under different seed number, you may try different seed if the code does not work well.

from lm-lstm-crf.

cosmozhang avatar cosmozhang commented on May 26, 2024

@jiesutd I also implemented Lample's structure using pytorch last year and got similar results. Thank you.

from lm-lstm-crf.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.