1
0
mirror of https://github.com/microsoft/qlib.git synced 2026-07-07 21:11:50 +08:00

bug & docs fixed

This commit is contained in:
lzh222333
2021-06-23 08:46:21 +00:00
committed by you-n-g
parent a7862387a2
commit d96f7a67c6
5 changed files with 22 additions and 10 deletions

View File

@@ -92,16 +92,16 @@ class Serializable:
@classmethod
def load(cls, filepath):
"""
Load the collector from a filepath.
Load the serializable class from a filepath.
Args:
filepath (str): the path of file
Raises:
TypeError: the pickled file must be `Collector`
TypeError: the pickled file must be `type(cls)`
Returns:
Collector: the instance of Collector
`type(cls)`: the instance of `type(cls)`
"""
with open(filepath, "rb") as f:
object = cls.get_backend().load(f)