h2o-tutorial | H2O Tuning and Ensembling Tutorial for R | Machine Learning library
kandi X-RAY | h2o-tutorial Summary
kandi X-RAY | h2o-tutorial Summary
A Definitive Guide to Tune and Combine H2O Models in R.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of h2o-tutorial
h2o-tutorial Key Features
h2o-tutorial Examples and Code Snippets
Community Discussions
Trending Discussions on h2o-tutorial
QUESTION
I'm following a tutorial from https://github.com/h2oai/h2o-tutorials/blob/master/tutorials/gbm-randomforest/GBM_RandomForest_Example.py
I have been following the tutorial until I reached the line with hit_ratio_table. when I executed "rf_v1.hit_ratio_table(valid=True)", I encounter the error below.
...ANSWER
Answered 2019-Jun-21 at 20:42The attribute is still there, it looks like the tutorial is missing a line of code right after the file import, which means the model is being considered as a regression problem instead of a classification problem. So if you add the following line after you import the covtype dataset:
covtype_df[54] = covtype_df[54].asfactor()
which converts the target to a factor, it should work.
If you want to play around with the hit_ratio_table()
you can look at this code snippet in the H2O-3 user guide.
QUESTION
I'm trying to create an ensemble model in H2O from a number of GLM, GBM, and deep learning models.
Here's what I did so far.
Import relevant libraries:
...ANSWER
Answered 2019-Feb-06 at 23:55It looks like you are missing the parameter keep_cross_validation_predictions=True
in each of your models. For example you would want to do the following for your GLM and then likewise for the other models you want to stack:
QUESTION
I'm trying to save all the models from an h2o.automl
as part of the h2o
package. Currently I am able to save a single model using h2o.saveModel(aml@leader, path = "/home/data/user")
.
How can I save all the models?
Here is my attempt on a sample dataset:
...ANSWER
Answered 2018-Sep-12 at 17:42Try this, it'll do your job:
QUESTION
Final Edit: this problem ended up occurring because the target array were integers that were supposed to represent categories so it was doing a regression. Once I converted them into factors using .asfactor()
, then the confusion matrix method detailed in the answer below worked
I am trying to run a confusion matrix on my Random Forest Model (my_model
), but the documentation has been less than helpful. From here it says the command is h2o.confusionMatrix(my_model)
but there is no such thing in 3.0.
Here are the steps to fit the model:
...ANSWER
Answered 2018-Aug-07 at 17:09please see the documentation for the full parameter list. For your convenience here is the list confusion_matrix(metrics=None, thresholds=None, train=False, valid=False, xval=False)
.
Here is a working example of how to use the method:
QUESTION
When trying to acquire the recall score using e.g.
...ANSWER
Answered 2017-Aug-14 at 20:28Starting with your 2nd question, Flow has a precision/recall curve (and it is interactive). Flow is always running on port 54321 of each node, i.e. http://127.0.0.1:54321
if you are running h2o locally.
I imagine that there is something interesting with your data or model, and that when you look at the precision/recall curve it will become clear.
In R if you do str(m)
(where m
is your model) you will see all the model data. m@training_metrics@metrics$thresholds_and_metric_scores$recall
holds the recall numbers for each threshold.
I cannot work out how to look inside the Python object, yet, but your call was correct. On my quick test (the iris dataset with a 2-category enum column added):
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install h2o-tutorial
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page