Skip to content

Commit

Permalink
format PEP8: storage.py
Browse files Browse the repository at this point in the history
  • Loading branch information
zhupr committed May 21, 2021
1 parent 8e6c744 commit 95b50de
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions qlib/data/storage/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,12 @@ def remove(self, value: CalVT) -> None:

@overload
def __setitem__(self, i: int, value: CalVT) -> None:
"""x.__setitem__(i, o) <==> x[i] = o"""
"""x.__setitem__(i, o) <==> (x[i] = o)"""
...

@overload
def __setitem__(self, s: slice, value: Iterable[CalVT]) -> None:
"""x.__setitem__(s, o) <==> x[s] = o"""
"""x.__setitem__(s, o) <==> (x[s] = o)"""
...

def __setitem__(self, i, value) -> None:
Expand Down Expand Up @@ -364,7 +364,12 @@ def rewrite(self, data: Union[List, np.ndarray, Tuple], index: int):

@overload
def __getitem__(self, s: slice) -> pd.Series:
"""x.__getitem__(slice(start: int, stop: int, step: int)) <==> x[start:stop:step] == pd.Series(values, index=pd.RangeIndex(start, len(values))"""
"""x.__getitem__(slice(start: int, stop: int, step: int)) <==> x[start:stop:step]
Returns
-------
pd.Series(values, index=pd.RangeIndex(start, len(values))
"""
...

@overload
Expand Down

0 comments on commit 95b50de

Please sign in to comment.