Comments (13)
@mdasadul you can do this:
cd ~/torch
./clean.sh
TORCH_LUA_VERSION=LUA52 ./install.sh
And then everything shoudl work
from opennmt.
it is probably the same than #20. can you check?
from opennmt.
Yes it's looks like they are same although he was getting it during saving the model but I am getting it middle of preprocessing
from opennmt.
Fixed by #29.
from opennmt.
Sorry to reopen the issue once again. I am trying to preprocess 20Millions sentences and i ended up getting the same error
PANIC: unprotected error in call to Lua API (not enough memory)
from opennmt.
Just to check though, did you get this error with the latest code? We switched to use tds
instead of lua tables to avoid this problem.
from opennmt.
@Rush yes I checked out the code this morning. I was having the issue previously with 10 Million sentences and after the tds fix it was resolved but when I increased the training data to 20 million I can see that error again.
@soumith Thanks for pointing out but right now I am middle of training another Seq2seq-attn model and If I reinstall torch it will interrupt current training
from opennmt.
(you can easily install another instance of torch in another directory, there won't be any interference with your current runs - keep us updated!)
from opennmt.
I'm interested to know when this error occurs. Can you share the full preprocessing logs and the command line you ran?
Switching to Lua 5.2 is indeed a definitive fix for this issue but we would like to push the memory limit as far as possible for other Lua versions. #29 already fixes the issue for most use cases though.
from opennmt.
I am using following command line
th preprocess.lua -train_src data/src-train.txt.tok -train_tgt data/targ-train.txt.tok -valid_src data/src-test.txt.tok -valid_tgt data/targ-test.txt.tok -save_data model/28dec
Also I am getting the error when it trying to process line 18349687. So your preprocess script can handle 18349686 sentences
from opennmt.
closing the issue for now. use LUA 5.2 is a fix.
from opennmt.
Seeing same issue with 8 GB, 32 GB & 256 GB RAM. must be something other than memory issue.
from opennmt.
This is a LuaJIT memory issue. The total memory of Lua objects (tables, strings) is limited to about 2GB.
from opennmt.
Related Issues (20)
- Decoder.lua:446: 'for' limit must be a number HOT 1
- Error when translating with Language Model: "attempt to call method 'forwardOne' (a nil value)" HOT 2
- Meet with lua:446:'for' limit must be a number HOT 2
- Difference between using epoch and train_steps HOT 3
- Difference bteween gnmt and brnn encoder HOT 2
- WriteObject problem, bad argument #1 to 'ipairs' HOT 1
- IDEA: Process FOSS projects .po files for translation corpora
- The engine caches the data in the translation HOT 6
- How to speed up when preprocess the corpus ? HOT 1
- Embeddings: invalid line count HOT 3
- Test BLEU Score HOT 1
- share_embedding option HOT 2
- Better pre-trained PyTorch models
- Maximum length of string processed by the engine HOT 2
- unicode issue for translating Bangla to English HOT 2
- Error BPE tokenizer: tokenize.lua:87: attempt to concatenate upvalue 'line' HOT 3
- Is early stopping available in OpenNMT-py or OpenNMT-tf? HOT 1
- Is `early-stopping` available feature in OpenNMT-tf or OpenNMT-py?
- NMT, What if we do not pass input for decoder? HOT 1
- ModuleNotFoundError: No module named 'onmt.inputters' HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opennmt.