您的位置:首页 > 其它

Torch7 Serialization

2015-08-19 17:26 465 查看
LINK: https://github.com/torch/torch7/blob/master/doc/serialization.md
Torch provides 4 high-level methods of serialize/deserialize arbitrary Lua/Torch objects. These functions are just abstractions over the File object, and were created for convenience (these are very common routines).

The first two functions are useful to serialize/deserialize data to/from files:

torch.save(filename, object [, format])
[object] torch.load(filename [, format])


The format can be set to ascii or binary (default is binary).

The next two functions are useful to serialize/deserialize data to/from strings:

[str] torch.serialize(object)
[object] torch.deserialize(str)
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  torch