Borrar filtros
Borrar filtros

automated change of number of neurons in a neural network

3 visualizaciones (últimos 30 días)
Mokhtar
Mokhtar el 29 de Sept. de 2022
Respondida: Shubh Dhyani el 4 de Nov. de 2022
Hello,
i am trying to train a DDPG agent for a multiple number of nodes pro hidden layer, and i wanna know what is the best number of neurons to take. i know that i have to do through trail and fail. and i wanna know is there a function where i can automate it. i mean if i can do the training for different number of neurons pro hidden layer like create an array x = [16 32 64 128 256] and train the network for each number in the array (number of nodes pro hidden layer) in a for loop ?

Respuestas (1)

Shubh Dhyani
Shubh Dhyani el 4 de Nov. de 2022
I understand that you are trying to train a DDPG agent for multiple numbers of nodes for hidden layers and want to know what is the best number of neurons that you can take. I am assuming that the word "best" signifies the most optimized value (having the least loss) of the number of neurons.
The number of neurons can be considered as a hyperparameter of the neural network. For finding the most optimal value of the number of neurons (layer size), you can use hyperparameter tuning methods. Although MATLAB has no specific hyperparameter tuning function, you can make use of Bayesian Optimization method for hyperparameter tuning.
You can refer to the following link for more information about the same :

Categorías

Más información sobre Sequence and Numeric Feature Data Workflows en Help Center y File Exchange.

Productos


Versión

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by