chainer.serializers.save_npz

chainer.serializers.save_npz(filename, obj, compression=True)

Saves an object to the file in NPZ format.

This is a short-cut function to save only one object into an NPZ file.

Parameters:
  • filename (str) – Target file name.
  • obj – Object to be serialized. It must support serialization protocol.
  • compression (bool) – If True, compression in the resulting zip file is enabled.