code: public static void save(Map<String,TernaryVector> wordToIndexVector, 
                              File output) {
          try {
              FileOutputStream fos = new FileOutputStream(output);
              ObjectOutputStream outStream = new ObjectOutputStream(fos);
              outStream.writeObject(wordToIndexVector);
              outStream.close();
          } catch (IOException ioe) {
              throw new IOError(ioe);
          }
      }
docs: Saves the mapping from word to {@link TernaryVector} to the specified
  file.