title: How to load file created with numpy.savez_compressed?
body: <p>I am saving a numpy array using the following <code>export_vectors</code> defined below. In this function, I load string values separated by space and then store them as floats in an numpy array.  </p>
  
  <pre><code>def export_vectors(vocab, input_filename, output_filename, dim):
      embeddings = np.zeros([len(vocab), dim])
      with open(input_filename) as f:
          for line in f:
              line = line.strip().split(' ')
              word = line[0]
              embedding = line[1:]
              if word in vocab:
                  word_idx = vocab[word]
                  embeddings[word_idx] = np.asarray(embedding).astype(float)
  
      np.savez_compressed(output_filename, embeddings=embeddings)
  </code></pre>
  
  <p>Here <code>embeddings</code> is an <code>ndarray</code> of <code>float64</code> type.</p>
  
  <p>Although, then when trying to load the file, using:</p>
  
  <pre><code>def get_vectors(filename):
      with open(filename) as f:
          return np.load(f)["embeddings"]
  </code></pre>
  
  <p>When trying to do the loading, I am getting the error:</p>
  
  <blockquote>
    <p>File "/usr/lib/python3.5/codecs.py", line 321, in decode
        (result, consumed) = self._buffer_decode(data, self.errors, final) UnicodeDecodeError: 'utf-8' codec can't decode byte 0x99 in position
    10: invalid start byte</p>
  </blockquote>
  
  <p>Why is this?</p>