Code Monkey home page Code Monkey logo

bert-event-extraction's People

Contributors

bowbowbow avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

bert-event-extraction's Issues

mislabeled data

Hi, I'm try to reproduce your model. But my result is low. I have checked these labels that my model predicted and I found a lot of labels that was predicted to Event sub-type difference to tag "O" but was tagged to 'O' tag in the dataset. Therefore, my precision score is downgrade( I only get precison=62%) . Did you encountered with this issue. If so, how did your tackled with it. You fixed wrong label in test, dev sets or keep the original data to evaluate these score?
Hope to see your answer soon! Thank you so much!

Two approaches to improve the performance

Hi,
I read your code and found there are two problems that hinder the performance improvement.
First, as I know, previous papers use head words of entity mentions as the candidate arguments, but you use the whole word sequence of entity mentions, which harms the argument-level performance a lot.
Second, while training, you train the argument-level classifier based on predicted triggers, instead, I believe the argument-level classifier should be trained on the golden triggers.

after remove entities and pos ,looking forward to reply,thanks

TypeError: new() received an invalid combination of arguments - got (NoneType, int), but expected one of:

  • (*, torch.device device)
    didn't match because some of the arguments have invalid types: (!NoneType!, !int!)
  • (torch.Storage storage)
  • (Tensor other)
  • (tuple of ints size, *, torch.device device)
  • (object data, *, torch.device device)

model architecture?

hi @bowbowbow, I am doing the end-of-the-year check up.
as i see it, i recognize that you tried some new approaches
to extract events while using bert.
I believe that the new approach can be captured by the NN architecture diagram

if it is possible, please add the diagram so that people can catch the new approach in a glance

thanks, yours sincerely, Yang

TypeError: new() received an invalid combination of arguments - got (NoneType, int), but expected one of: * (*, torch.device device)

Traceback (most recent call last):
File "D:/pythonProject/bert-event-extraction-master/train.py", line 80, in
model = Net(
File "D:\pythonProject\bert-event-extraction-master\model.py", line 18, in init
self.entity_embed = MultiLabelEmbeddingLayer(num_embeddings=entity_size, embedding_dim=entity_embedding_dim, device=device)
File "D:\pythonProject\bert-event-extraction-master\model.py", line 129, in init
self.matrix = nn.Embedding(num_embeddings=num_embeddings,
File "D:\anaconda2020\lib\site-packages\torch\nn\modules\sparse.py", line 109, in init
self.weight = Parameter(torch.Tensor(num_embeddings, embedding_dim))
TypeError: new() received an invalid combination of arguments - got (NoneType, int), but expected one of:

  • (*, torch.device device)
    didn't match because some of the arguments have invalid types: (!NoneType!, !int!)
  • (torch.Storage storage)
  • (Tensor other)
  • (tuple of ints size, *, torch.device device)
  • (object data, *, torch.device device)

head_indexes_2d是干什么用的

x是[batch_size,SEQ_LEN,768]的bert表达
有一句代码:
for i in range(batch_size):
x[i] = torch.index_select(x[i], 0, head_indexes_2d[i])
请问这是在做什么?

关于结果的疑问

不知道您读过这篇文章没有:《Exploring Pre-trained Language Models for Event Extraction and Generation
Sen》

他直接吧trigger的识别准确率推到了80%
image

Is this model a joint method or pipeline method?

I'm a freshman in Event Extraction. I have learned your code. In the train.py, I think this is a multitask because the loss is the sum of triggers loss and arguments loss. So i don't is this model a joint method or pipeline method?

input of a sentence

hi @bowbowbow, I am doing the end-of-the-year check up.
it processes the preprocessed data, but some people may utilize it for a sentence
that they want to process.

is it possible to input a sentence and check the output events within the input sentence?
if so, please add the description for it in README

thanks, yours sincerely, Yang

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.