saving the type of nparray when serializing, restoring to nparray when deserializing