Skip to content

Commit

Permalink
fix: revert forcing numpy array conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
gavincyi committed Aug 19, 2023
1 parent 0832b84 commit 6676fef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/fpm_risk_model/risk_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ def _to_numpy(values: Union[ndarray, DataFrame]) -> ndarray:
if values is None:
return values
elif isinstance(values, (DataFrame, Series)):
return np.array(values.values)
return values.values
elif isinstance(values, ndarray):
return np.array(values)
return values
else:
raise TypeError(
"Expect either pandas DataFrame or numpy array, "
Expand Down

0 comments on commit 6676fef

Please sign in to comment.