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
Add Support for Other ML Libraries #397
Comments
I think there's some great low hanging fruit here in the short term, with even more exciting opportunities for the long term. One thing I want to understand better - could you clarify how you were envisioning the integration of ATM? Are you thinking that the ATM would occur prior to visualization, or were you thinking that visualization is separate from any model tuning? |
@mitevpi I think the initial idea with ATM was to create a multi-model comparison visualizer that could be generated either during tuning to show progress, or after tuning to demonstrate the scope of the autotuning and its findings (so both?). Because this visualization would be ATM-specific, and possibly require some interactivity/liveness we haven't really had the opportunity to do a deep-dive into what this might look like. |
CC: @carlomazzaferro |
Was just trying to create a ResidualsPlot with a TensorFlow regression model today. Since the keras api has a |
@mattharrison did you get an exception when you tried to use the ResidualsPlot with the Keras model? I agree that it is low hanging fruit, and we've had good experience in the past with things just working, like XGBoost. |
I did. Here's some code to create a model:
And here is the error:
|
Ah, thank you @mattharrison! You know, I think @carlomazzaferro was working on this a while back -- perhaps he would be interested? |
See also #637! |
Just as a heads up, you can make keras work with yellowbrick with minimal work, just like this:
Note that you need to import the sklearn wrapper for keras, which unfortunately is not fully compliant with the sklearn api, and does not have the required attribute The same pattern holds for a classifier (tested it against the ROCAUC API), |
Thanks for sharing this! |
@carlomazzaferro thanks so much for this work. This is a clever implementation. I'm looking forward to playing with this. You're also welcome to contribute this to |
Thanks @ndanielsen ! I had worked on something similar for skorch as well, which is very similar role to keras' scikit-learn wrapper but for pytorch. I think these small examples could maybe be added to the docs, or at least on some sample notebooks? I know that adding full support for either keras, torch or tensorflow would be a massive undertaking, but some minimal working examples could be useful for people that currently using the high-level wrappers. Something along the lines of #637 . |
@carlomazzaferro that's an even better idea. I think that we can likely add a reference in the docs to the example notebooks. |
Cool! I'll work on getting some examples going and I'll do a pull request. |
I independently had the same thought and took a shot at mating I'd be happy to try and figure out if broad compatibility is possible for a PR, if that's still of interest. The tricky bit is that for most of the interesting plot types, like e.g. |
@ResidentMario Thank you for this awesome work. I encourage you to open a PR. However we won’t be able to review it for 2-3 weeks as we are on a short hiatus. Here is a link to our contributor’s guide. http://www.scikit-yb.org/en/latest/contributing.html here is an example of a wrapper for statsmodel https://github.com/DistrictDataLabs/yellowbrick/blob/d6ebc391e0c2e7aeb57ab14396ccc11b67ee0790/yellowbrick/contrib/statsmodels/base.py |
FYI, the write-up is now published to the Towards Data Science mailer on Medium. |
@ResidentMario such a great write up - thank you so much! We would be certainly interested in a contrib model for Keras if you ever want to pursue it! |
This PR introdues a wrapper for estimators that implement the scikit-learn API but do not extend BaseEstimator. If the estimator is missing required properties (generally the learned attributes) then a sensible error is raised. Includes documentation about how to use non-sklearn estimators with Yellowbrick. Closes #1098, closes #1099, closes #397
We currently have an experimental wrapper for StatsModels in : #383
It would be fantastic if we can add visualizer support for Tensorflow, Keras and other classification selection visualizers using ATM.
The text was updated successfully, but these errors were encountered: