Giter Club home page Giter Club logo

Comments (5)

jlyang1990 avatar jlyang1990 commented on May 13, 2024 2

I see. The only difference between FastTreeSHAP v0.1.3 and v0.1.2 is that the restriction of numpy version (numpy<1.22) has been removed (41a33b6). The same thing has been done when SHAP upgraded its own version to v0.41.0 (shap/shap@23081f5). We believe that this additivity check failure issue was brought up by this restriction removal (see #15 for more details).

Since FastTreeSHAP library aims to reproduce the results from SHAP library in a more efficient way, we would like to wait until SHAP library implements effective resolutions to fix this issue. In the meantime, I would recommend you to switch to FastTreeSHAP v0.1.2 to bypass this issue.

from fasttreeshap.

jlyang1990 avatar jlyang1990 commented on May 13, 2024

Does the additivity check failure issue also exist when running SHAP on the same dataset?

from fasttreeshap.

Jing25 avatar Jing25 commented on May 13, 2024

No. It's interesting that when using SHAP with feature_perturbation=“tree_path_dependent”, the expected value before computing any shap values for a dataset, is different from the expected value after the computation. That means, I got the expected value == 0 before doing any computation, but after I run it on a dataset, the expected value became 2.155. This holds for the previous version. In the previous version (0.38.0 and 0.40.0), I got the expected value ==2.17 before any computation and 2.155 after the computation. I don't know why this is the case.

from fasttreeshap.

jlyang1990 avatar jlyang1990 commented on May 13, 2024

Sorry I'm a bit confused. Did you say that in the previous version (0.38.0 and 0.40.0), you got the expected value ==2.17 before any computation and 2.155 after the computation, and in the current version (0.41.0), you got the expected value ==0 before any computation and 2.155 after the computation? If so, which version does FastTreeSHAP match? Thanks!

from fasttreeshap.

Jing25 avatar Jing25 commented on May 13, 2024

Sorry I'm a bit confused. Did you say that in the previous version (0.38.0 and 0.40.0), you got the expected value ==2.17 before any computation and 2.155 after the computation, and in the current version (0.41.0), you got the expected value ==0 before any computation and 2.155 after the computation?

That is correct. Sorry to make it confusing by mixing with different versions. This inconsistency is only observed in SHAP, not in FastTreeSHAP.

If so, which version does FastTreeSHAP match?

The expected value of FastTreeSHAP 0.1.3 matches the latest version SHAP (0.41.0), which is 0. Then the error came out when I try computing the shap values for a dataset.

The older version works fine (for example, 0.1.1), because the expected value is 2.17, which matches the older version SHAP.

from fasttreeshap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.