-
Notifications
You must be signed in to change notification settings - Fork 109
Open
Description
In choice_calcs.py line 930, it appears the library is calling rows_to_obs.toarray() which converts a sparse array to a potentially huge dense array (for my use case, the resulting sparse array is small, and the dense version is about 200 GiB).
Here is the existing code:
weights_per_obs =\
np.max(rows_to_obs.toarray() * weights[:, None], axis=0)
Is the intended behavior given below?
M = rows_to_obs.multiply(weights.reshape(-1,1))
weights_per_obs = np.max(M, axis=0).toarray().reshape(-1)
If so, I think this is a simple fix.
guidopetri and mathijsvdv
Metadata
Metadata
Assignees
Labels
No labels