TurboParser icon indicating copy to clipboard operation
TurboParser copied to clipboard

Assertion failed when loading parser model

Open vene opened this issue 11 years ago • 3 comments

Did recent changes break compatibility with old parser models? I am behind a slow internet connection and only have the parser models distributed with version 2.1.0. With current master I get this:

turboparser-dev [master●●] % echo "I solved the problem with statistics." | scripts/parse.sh
F0823 14:55:12.762917 1989362448 Alphabet.cpp:86] Check failed: success
*** Check failure stack trace: ***
    @        0x10848f2ea  google::LogMessage::Fail()
    @        0x10848e6c0  google::LogMessage::SendToLog()
    @        0x10848f0c0  google::LogMessage::Flush()
    @        0x108492bd8  google::LogMessageFatal::~LogMessageFatal()
    @        0x10848f745  google::LogMessageFatal::~LogMessageFatal()
    @        0x10837b81b  Alphabet::Load()
    @        0x10834eb34  DependencyDictionary::Load()
    @        0x10837fba7  Pipe::LoadModel()
    @        0x10833905a  DependencyPipe::LoadModel()
    @        0x10837fa9d  Pipe::LoadModelByName()
    @        0x10835ccec  Pipe::LoadModelFile()
    @        0x10835c894  TestParser()
    @        0x10835c22a  main
    @     0x7fff871a55fd  start
    @                0x6  (unknown)
/Users/mbk-59-41/code/turboparser-dev/scripts/run_parser.sh: line 33:  8444 Abort trap: 6           ${path_bin}/TurboParser --test --evaluate --file_model=${file_model} --file_test=${file_test} --file_prediction=${file_prediction}

However, running scripts/train_test_parser.sh sample works great, and I can predict using the trained model.

I thought it might be an artifact of compiling with/without libc++ as reported in #4 but I get the same error either way. I also checked with version 2.2.0 as released on the website, building in all possible ways, and the models work.

vene avatar Aug 23 '14 13:08 vene

Unfortunately they did (I implemented projective parsing and had to add a flag to signal that a model is projective). The version in the web site should work (but doesn't include projective parsing...)

Once I have some time, I will provide a new version and release new models.

Andre'

2014-08-23 14:00 GMT+01:00 Vlad Niculae [email protected]:

Did recent changes break compatibility with old parser models? I am behind a slow internet connection and only have the parser models distributed with version 2.1.0. With current master I get this:

turboparser-dev [master●●] % echo "I solved the problem with statistics." | scripts/parse.sh F0823 14:55:12.762917 1989362448 Alphabet.cpp:86] Check failed: success *** Check failure stack trace: *** @ 0x10848f2ea google::LogMessage::Fail() @ 0x10848e6c0 google::LogMessage::SendToLog() @ 0x10848f0c0 google::LogMessage::Flush() @ 0x108492bd8 google::LogMessageFatal::~LogMessageFatal() @ 0x10848f745 google::LogMessageFatal::~LogMessageFatal() @ 0x10837b81b Alphabet::Load() @ 0x10834eb34 DependencyDictionary::Load() @ 0x10837fba7 Pipe::LoadModel() @ 0x10833905a DependencyPipe::LoadModel() @ 0x10837fa9d Pipe::LoadModelByName() @ 0x10835ccec Pipe::LoadModelFile() @ 0x10835c894 TestParser() @ 0x10835c22a main @ 0x7fff871a55fd start @ 0x6 (unknown) /Users/mbk-59-41/code/turboparser-dev/scripts/run_parser.sh: line 33: 8444 Abort trap: 6 ${path_bin}/TurboParser --test --evaluate --file_model=${file_model} --file_test=${file_test} --file_prediction=${file_prediction}

However, running scripts/train_test_parser.sh sample works great, and I can predict using the trained model.

I thought it might be an artifact of compiling with/without libc++ as reported in #4 https://github.com/andre-martins/TurboParser/issues/4 but I get the same error either way. I also checked with version 2.2.0 as released on the website, building in all possible ways, and the models work.

— Reply to this email directly or view it on GitHub https://github.com/andre-martins/TurboParser/issues/5.

andre-martins avatar Aug 23 '14 22:08 andre-martins

Cool, thanks!

How about adding a version field to the model files so that the error messages can be made more user friendly?

vene avatar Aug 23 '14 22:08 vene

That's a good idea. I will do that for the next versions. Another possibility for making things backward-compatible is to use protocol buffers (or something alike) allowing for some fields to be optional and default to a prespecified value. Most of the changes between versions involve adding new flags, and this would solve that problem.

Andre'

2014-08-23 23:29 GMT+01:00 Vlad Niculae [email protected]:

Cool, thanks!

How about adding a version field to the model files so that the error messages can be made more user friendly?

— Reply to this email directly or view it on GitHub https://github.com/andre-martins/TurboParser/issues/5#issuecomment-53168546 .

andre-martins avatar Aug 24 '14 11:08 andre-martins