Giter Club home page Giter Club logo

data2text-entity-py's People

Contributors

ratishsp 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

Watchers

 avatar  avatar  avatar  avatar

data2text-entity-py's Issues

Error with backprop

Hello! I'm trying to reproduce the results of this code and I'm getting the following error:

    main()
  File "train.py", line 494, in main
    train_model(model, fields, optim, data_type, model_opt)
  File "train.py", line 257, in train_model
    train_stats = trainer.train(train_iter, epoch, report_func)
  File "/Users/sanjana/destruct/data2text-entity-py/onmt/Trainer.py", line 176, in train
    self._gradient_accumulation(
  File "/Users/sanjana/destruct/data2text-entity-py/onmt/Trainer.py", line 316, in _gradient_accumulation
    batch_stats = self.train_loss.sharded_compute_loss(
  File "/Users/sanjana/destruct/data2text-entity-py/onmt/Loss.py", line 122, in sharded_compute_loss
    for shard in shards(shard_state, shard_size):
  File "/Users/sanjana/destruct/data2text-entity-py/onmt/Loss.py", line 265, in shards
    torch.autograd.backward(inputs, grads, retain_graph=True)
  File "/Users/sanjana/miniconda3/lib/python3.8/site-packages/torch/autograd/__init__.py", line 125, in backward
    Variable._execution_engine.run_backward(
RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.FloatTensor [1200, 600]], which is output 0 of TBackward, is at version 2; expected version 1 instead. Hint: the backtrace further above shows the operation that failed to compute its gradient. The variable in question was changed in there or anywhere later. Good luck!

Any guidance would be really appreciated. Thank you! @ratishsp

size don't match (606,602)

Hi, when I use your code, there is a problem, it's "Not all arguments have the same value:", which is caused by aeq(sourceL, src_len) in GlobalAttention.py. And I find that length of entities_list and src data , which is 602 and 606 respectively. Apparently, this is because of <unk>,<blank>,</s> and <s>. But when I restrict the length of src data to 602, the model could run normally, but the score of RG/CS/CO is too low.

Please help me .

Question about evalution with torch

Hi,

When I run the evalution with
CUDA_VISIBLE_DEVICES=6 ~/torch/install/bin/th extractor.lua -gpuid 1 -datafile roto-ie.h5 -preddata drive_data/transform_gen/roto_cc-beam5_gens.h5 -dict_pfx "roto-ie" -just_eval, I'm faced with the following error.
/root/torch/install/bin/luajit: extractor.lua:574: bad argument #1 to 'copy' (sizes do not match at /root/torch/extra/cutorch/lib/THC/THCTensorCopy.cu:31)
I print the size and find that the size of p (parameters of generated model) is 2234733, and the size of saved_p (parameters from conv1ie-ep6-94-74.t7) is 2141733. How can I solve the problem?

My torch is installed with LuaJIT. The hdf5 is installed with 'luarocks install hdf5'.

Thank you

Yixian

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.