Editing
Neural Architecture Search
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== <span style="color: #FFFFFF;">Applying</span> == '''Architecture search with DARTS (simplified):''' <syntaxhighlight lang="python"> import torch import torch.nn as nn import torch.nn.functional as F OPERATIONS = { 'skip_connect': lambda C: nn.Identity(), 'sep_conv_3x3': lambda C: SepConv(C, C, 3, 1), 'dil_conv_5x5': lambda C: DilConv(C, C, 5, 2, 2), 'max_pool_3x3': lambda C: nn.MaxPool2d(3, 1, 1), 'avg_pool_3x3': lambda C: nn.AvgPool2d(3, 1, 1, count_include_pad=False), } class MixedOp(nn.Module): """A mixed operation where each candidate is weighted by architecture parameter.""" def __init__(self, C): super().__init__() self.ops = nn.ModuleList([op(C) for op in OPERATIONS.values()]) def forward(self, x, weights): # weights: softmax of architecture parameters Ξ± return sum(w * op(x) for w, op in zip(weights, self.ops)) # Architecture parameters (separate from network weights) arch_params = nn.Parameter(torch.randn(n_edges, len(OPERATIONS))) # Bi-level optimization: # 1. Update network weights on train set (standard gradient) # 2. Update arch_params on val set (gradient through mixed ops) # Final: discretize by argmax(softmax(arch_params)) per edge </syntaxhighlight> ; NAS approach selection : '''Compute budget <1 GPU-day''' β DARTS, GDAS, or random search (surprisingly competitive) : '''Hardware-specific target''' β ProxylessNAS, SNAS, Once-for-All : '''Zero search cost''' β Zero-cost proxies (NASWOT, synflow) β correlate with performance without training : '''Production ML teams''' β AutoML platforms: Google AutoML, Azure AutoML, Auto-Sklearn </div> <div style="background-color: #8B4500; color: #FFFFFF; padding: 20px; border-radius: 8px; margin-bottom: 15px;">
Summary:
Please note that all contributions to BloomWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
BloomWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
What links here
Related changes
Special pages
Page information