ustunb / actionable-recourse Goto Github PK
View Code? Open in Web Editor NEWpython tools to check recourse in linear classification
License: BSD 3-Clause "New" or "Revised" License
python tools to check recourse in linear classification
License: BSD 3-Clause "New" or "Revised" License
I am considering applying your tool to solve more complicated problems(more complicated inputs and models), but I worry about the time and spatial complexity.
So I wonder that, in your experiments, if given one case of input and the linear classifier gets a negative output, how much time and memory does it need to solve the integer programming and give the flipset? Does it take a very long time and very much memory? And how about a large number of cases?
What is the reason behind reproducing the same actionable recourse for the same instance although the RecouseBuilder fit twice seperately?
Did you experiment with non-linear models? If so what are the notes?
If not, why? What would be an approach to get recourse on more complex models (DNN) ?
Is it possible with this implementation to impose a sum constraints on one-hot encoded feature columns, so that only one of the colums can be set to 1?
e.g. if you have features x1 x2 x3 = (0,0,1) then (1,0,1) should not be a returned as a counterfactual.
I didn't find it in the code, but it's mentioned in the paper: "Customizing the Action Space.Users can easily customize the set of feasible actions by addinglogical constraints to the IP. These constraints can be used when, for example, a classifier uses dummyvariables to encode a categorical attribute (i.e., a one-hot encoding)."
Did I overlook it?
Thanks!
pip install actionable-recourse
leads to the following output for me:
[...]
Requirement already satisfied: pyomo>=5.6.1 in /usr/lib/python3.8/site-packages (from actionable-recourse) (5.6.9)
ERROR: Could not find a version that satisfies the requirement cplex>=12.8 (from actionable-recourse) (from versions: none)
ERROR: No matching distribution found for cplex>=12.8 (from actionable-recourse)
As CBC and pyomo are up-to-date and pyomo is detected, I wonder why CPLEX errors still prevent the installation.
Note: As this appeared only after I updated my kernel, the error is possibly connected to an issue about my setup that I do not understand.
After setting up the library I executed the notebook in the usage section and it gives,
AttributeError: 'ActionSet' object has no attribute 'align'
how to fix this issue?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.