-
-
Notifications
You must be signed in to change notification settings - Fork 316
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
Number of layers #204
Comments
Hi BenLim88, First of all, i usually use "if {{choice(['three', 'four'])}} as condition and you might want to double check it. |
Dear Jeremy Thanks for the reply. How would you write the code if you are trying to iterate through, say, 2, 3 and 4 layers? I assume you will start by adding 2 dense layers: Then run the condition, for the 3rd layer: For the 4th layer, i presume it has to be nested within the 'if' statement for the 3rd layer, but i'm unsure if it is correct. |
@BenLim88 you should only evaluate model = ...
num_layers = <result of randint>
for _ in range(num_layers):
model.add(Dense({{choice([np.power(2,5),np.power(2,9),np.power(2,11)])}}))
model.add(Activation({{choice(['tanh','relu', 'sigmoid'])}}))
model.add(Dropout({{uniform(0, 1)}})) |
could i define the search range for number of layers as well? e.g. choice([10,20,30]) for 10, 20 and 30 layers? |
Does anyone know how Hyperas deals with choices in a "if" statement? I added a choice for the dropout for each layer. Hyperas can chose between three to seven layers, with different dropout and nodes for each layer. Does Hyperas try to tune for values behind an if-statement? |
This solution works great, but when it comes to the |
We can use the following for number of layers (assuming 2 dense layers have been already defined), according to the examples:
Is there a way to add the number of layers by means of a number? e.g. 10 = 10 dense layers.
I tried this, but in the best_run, it gives me 15 dense layers, which does not reflect the actual results
The text was updated successfully, but these errors were encountered: