swiseman / nn_coref Goto Github PK
View Code? Open in Web Editor NEWNeural Coref Models
License: GNU General Public License v3.0
Neural Coref Models
License: GNU General Public License v3.0
Hiya!
I'm trying to compile the modifiedBCS stuff and getting
[error] ./src/main/java/edu/harvard/nlp/moarcoref/MiniDriver.java:15: cannot find symbol
[error] symbol: variable WRITE_FEATS_SEP
[error] location: class edu.harvard.nlp.moarcoref.MiniDriver.Mode
[error] public static Mode mode = Mode.WRITE_FEATS_SEP;
[error] (compile:compileIncremental) javac returned nonzero exit code
[error] Total time: 32 s, completed Feb 8, 2017 1:22:34 PM
Should the Mode
enum in that class have another value?
Hi!
Thanks for the code!
I'm trying to run the command to extract the features using the pre-compiled moarcoref-assembly-1.jar, and I get the message below about invalid options:
java -jar -Xmx30g modifiedBCS/moarcoref-assembly-1.jar ++modifiedBCS/base.conf -execDir /home/loaiciga/coref/features/ -numberGenderData /home/loaiciga/coref/conll-2012/gender.data -animacyPath /home/loaiciga/coref/conll-2012/animate.unigrams.txt -inanimacyPath /home/loaiciga/coref/conll-2012/inanimate.unigrams.txt -trainPath /home/loaiciga/coref/conll-2012/flat_train_2012 -devPath /home/loaiciga/coref/conll-2012/flat_dev_2012 -testPath /home/loaiciga/coref/conll-2012/flat_test_2012 -mode SMALLER -conjType NONE -pairwiseFeats FINAL+MOARANAPH+MOARP
Invalid enum: 'SMALLER'; valid choices: WRITE_FEATS_SEP
And using the WRITE_FEATS_SEP option, doesn’t produce the OPCs.txt files.
Any suggestions?
Thanks again,
Sharid
Hi Sam,
I've encountered an issue I believe related to hdf5 when running the vanilla_mr.lua. I have installed all necessary packages (nn, hdf5), and have put all resources in their right location (hdf5 files and other required data). When running th vanilla_mr.lua, the following error appears:
$ th vanilla_mr.lua -PT
/Users/Thanakorn/torch/install/bin/lua: /Users/Thanakorn/torch/install/share/lua/5.2/hdf5/group.lua:312: HDF5Group:read() - no such child 'feats' for [HDF5Group 33554432 /]
stack traceback:
[C]: in function 'error'
/Users/Thanakorn/torch/install/share/lua/5.2/hdf5/group.lua:312: in function </Users/Thanakorn/torch/install/share/lua/5.2/hdf5/group.lua:302>
(...tail calls...)
./sparse_doc_data.lua:10: in function 'loadFromH5'
vanilla_mr.lua:307: in function 'main'
vanilla_mr.lua:349: in main chunk
[C]: in function 'dofile'
...korn/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
[C]: in ?
Any suggestions would be appreciated! Thanks!
Hi Sam,
Let me first thank you. Your implementation helped me understand a lot of stuff with coreference, Torch and neural networks.
I am trying to use your version of the Berkeley feature extractor under modifiedBCS but I am having trouble using it for gold mentions. I used it on automatic mentions already without problems.
Here is what I tried:
java -jar -Xmx30g modifiedBCS/target/scala-2.11/moarcoref-assembly-1.jar ++modifiedBCS/base.conf -execDir execdir -numberGenderData modifiedBCS/gender.data -animacyPath modifiedBCS/animate.unigrams.txt -inanimacyPath modifiedBCS/inanimate.unigrams.txt -trainPath ./data/flat_gold_conll_train_2012/ -devPath ./data/flat_gold_conll_dev_2012/ -testPath ./data/flat_test_2012/ -mode SMALLER -conjType NONE -pairwiseFeats FINAL+MOARANAPH+MOARPW -trainOnGold
main() {
Execution directory: execdir
Using conjType = NONE
Reading Bergsma and Lin file from modifiedBCS/gender.data
Done!
ERROR: java.lang.IllegalArgumentException: requirement failed:
scala.Predef$.require(Predef.scala:207)
edu.harvard.nlp.moarcoref.FeatureExtractor$.writeSeparatedFeatsAndOraclePredClustering(FeatureExtractor.scala:24)
edu.harvard.nlp.moarcoref.FeatureExtractor.writeSeparatedFeatsAndOraclePredClustering(FeatureExtractor.scala)
edu.harvard.nlp.moarcoref.MiniDriver.run(MiniDriver.java:70)
edu.berkeley.nlp.futile.fig.exec.Execution.runWithObjArray(Execution.java:479)
edu.berkeley.nlp.futile.fig.exec.Execution.run(Execution.java:432)
edu.harvard.nlp.moarcoref.MiniDriver.main(MiniDriver.java:64)
Execution directory: execdir
1 errors, 0 warnings
} [3.9s]
The following line seems to be my problem (FeaturExtractor.scala):
def writeSeparatedFeatsAndOraclePredClustering(smaller:Boolean) {
...
require(!MiniDriver.trainOnGold);
...
Why are you disabling gold mentions? I tried using the options -trainOnGold
, -useGoldMentions
, -docSuffix gold_conll
to no avail.
I run the python script, but get the error:
luarocks/loader.lua:154: Invalid data in manifest file for module libcr (invalid data for cr scm-1)
stack traceback:
[C]: in function 'error'
.../torch/install/share/lua/5.2/trepl/init.lua:384: in function 'require'
init.lua:3: in main chunk
[C]: in function 'dofile'
full_g1_model.lua:2: in main chunk
[C]: in function 'dofile'
.../torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
[C]: in ?
I cd to the "nn" folder and compile: "luarocks make cr-scm-1.rockspec" and then re-run, but the problem still remains..
Anybody know the issue?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.