Skip to content
This repository has been archived by the owner on Mar 19, 2024. It is now read-only.

Windows 7 MinGW-W64 build produces a corrupted model file #76

Closed
S-Eugene opened this issue Sep 9, 2016 · 1 comment
Closed

Windows 7 MinGW-W64 build produces a corrupted model file #76

S-Eugene opened this issue Sep 9, 2016 · 1 comment

Comments

@S-Eugene
Copy link

S-Eugene commented Sep 9, 2016

fastText built on Windows 7 with MinGW-W64 gcc version 4.9.2 (x86_64-posix-seh-rev1) creates a model file that is not loaded correctly in test or predict modes.
Can be fixed by explicitly specifying std::ifstream ifs(filename, std::ifstream::binary); in FastText::loadModel and std::ofstream ofs(args_->output + ".bin", std::ofstream::binary); in FastText::saveModel in fasttext.cc

@S-Eugene S-Eugene changed the title Windows 7 MinGW-W64 build produces a corrupted the model file Windows 7 MinGW-W64 build produces a corrupted model file Sep 9, 2016
@EdouardGrave
Copy link
Contributor

Thanks for your report. This is now fixed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants