Skip to content

Commit

Permalink
Replace np.bool with bool
Browse files Browse the repository at this point in the history
  • Loading branch information
Chaoyingz committed May 5, 2023
1 parent 6f86c5b commit c10d69a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion qlib/data/dataset/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ def __init__(
# NOTE: bool(np.nan) is True !!!!!!!!
# make sure reindex comes first. Otherwise extra NaN may appear.
flt_data = flt_data.swaplevel()
flt_data = flt_data.reindex(self.data_index).fillna(False).astype(np.bool)
flt_data = flt_data.reindex(self.data_index).fillna(False).astype(bool)
self.flt_data = flt_data.values
self.idx_map = self.flt_idx_map(self.flt_data, self.idx_map)
self.data_index = self.data_index[np.where(self.flt_data)[0]]
Expand Down

0 comments on commit c10d69a

Please sign in to comment.