-
Notifications
You must be signed in to change notification settings - Fork 186
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
Cannot perform DataFrame operations on generated counterfactuals #388
Comments
@LakshmanKishore, you could save the generated counterfactuals as a .csv file on the disk like following:-
You could then consume the counterfactuals for whichever query point by reading the .csv file.
Let us know if that can address your concern. |
This is a workaround that I already have found. As you can see from the screenshots above. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm using dice-ml - 0.6.1 version. I wanted to perform some DataFrame operations on the generated counterfactuals.
Here I have the results of the generated counterfactuals.
This is the DataFrame that was generated, and I wanted to replace the target column with the original value (unencoded value), but I failed to replace the value, after some search I found a workaround.
This is the way I found by which I can modify the DataFrame and which will affect in the cfs.to_json() method.
In Regression Problem, the counterfactuals generated contained too many decimals which should be rounded, so I used the same way i.e, modifying the final_cfs_df dataframe to round the decimals.
Can we have a method which can perform all the DataFrame operations that directly affects the to_json() method?
The text was updated successfully, but these errors were encountered: