-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MemoryError: Unable to allocate sufficient memory #31
Comments
According to the error message I see that you want to explain 8 million variables. The matrix raising the memory error consumes O(N^2) with You can try the code below with different combinations of
|
I have no idea where the 8mio variables would be coming from. The dataset I was testing this on had only 23 input variables which is pretty basic. I tried running the sample code you shared with I tried with even smaller number of input variables (5) and training dataset with only 100 records. This time I get a
|
Could you provide a minimal snippet of code that represents your data/code and raises the error? If the computed matrix is not invertible, you may add a small amount of random noise in your data to avoid linear dependencies between columns. |
@kaalen could you provide an update please? What did you do ? |
Issue Description
I used a Random Survival Forest with 10 estimators and a max depth of 25 on approximately 1800 data samples. The full dataset otherwise contains approximately 200,000 data samples, but I intentionally only used a very small sample when I encountered this error.
When attempting to fit a ModelSurvSHAP on this very small dummy random survival forest I encounter the following error:
MemoryError: Unable to allocate 512. TiB for an array with shape (8388608, 8388608) and data type float64
I'm using survshap version 0.4.2.
Minimal Reproducible Code Sample
Error Trace:
The text was updated successfully, but these errors were encountered: