unable to control the optimization of some hyperparameters
조회 수: 1 (최근 30일)
이전 댓글 표시
I'm trying to optimize the hyperparmeters (number of layers and number of nodes in each layer) for a Stacked auto encoder as follows:
optimVars = [optimizableVariable('numLayers',[1 3],'Type','integer') % number of layers
optimizableVariable('layer1_Size',[500 1000],'Type','integer') % number of nodes in the first layer
optimizableVariable('layer2_Size',[500 400],'Type','integer') % number of nodes in the 2nd layer
optimizableVariable('layer3_Size',[400 50],'Type','integer') % number of nodes in the 3rd layer
];
but this way I'm facing a problem which is for example: when the optimizer runs an iteration with numbLayers=1, the
optimzer will optimize the last two variables (layer2_Size & layer3_Size) which in such a case are not needed to optimize because
the only variable needs to be optimized in this case is "layer1_Size" . Is there any way to solve this problem by setting a variable on/off depending on another variable value?
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Get Started with Optimization Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!