You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GridSearchCV is a great way to test and optimize hyper-parameters automatically. I use it with TensorFlowEstimator to optimize learning_rate, batch_size, ...etc. It would be a great addition if I can also use it to customize other parameters in my custom model.
For example, say I have a custom model with a convnet and I want to optimize the stride value. This pseudo code explains what I'm trying to achieve.
I used a custom "params" input to the model function just as an example, not to imply that this is necessarily the right way to implement this feature.
# My custom model.
# Feature request: New params dict with values filled by GridSearchCV
def cnn_model(X, Y, params):
stride = params['stride']
... custom model definition here ...
# Create the Convnet classifier
cnn_classifier = learn.TensorFlowEstimator(model_fn=cnn_model)
# Grid search on different stride values.
parameters = {'stride': [1, 2, 3],}
grid_searcher = GridSearchCV(cnn_classifier, parameters)
grid_searcher.fit(X, Y)
The text was updated successfully, but these errors were encountered:
Model function has params argument. TensorFlowEstimator is deprecated, please use Estimator that takes params argument. This should work now, please re-open if this doesn't.
GridSearchCV is a great way to test and optimize hyper-parameters automatically. I use it with TensorFlowEstimator to optimize learning_rate, batch_size, ...etc. It would be a great addition if I can also use it to customize other parameters in my custom model.
For example, say I have a custom model with a convnet and I want to optimize the stride value. This pseudo code explains what I'm trying to achieve.
I used a custom "params" input to the model function just as an example, not to imply that this is necessarily the right way to implement this feature.
The text was updated successfully, but these errors were encountered: