Memory efficient library to work with word vectors
```rust
let space = Word2VecParser::new() // Parse binary file .binary() // Index terms to find vectors faster. .indexterms(true) .parsefile("./GoogleNews-vectors-negative300.bin") .unwrap();
let hello = space.findterm("hello").unwrap(); let hi = space.findterm("hi").unwrap(); println!("{}", hello.cosine(&hi));
```
```rust // Load a space let space = Word2VecParser::new() .binary() .indexterms(true) .parsefile("./GoogleNews-vectors-negative300.bin") .unwrap();
// export space to .vec file let out = BufWriter::new(File::create("GoogleNews-vectors-negative300.vec").unwrap()); Exporter::new(out).export_space(&space).unwrap();
```