saving the type of nparray when serializing, restoring to nparray when deserializing
merged with yet-more-apis