(self, width=16)
| 2144 | class ConditionalGradientModel(torch.nn.Module): |
| 2145 | |
| 2146 | def __init__(self, width=16): |
| 2147 | super().__init__() |
| 2148 | self.scale = torch.nn.Parameter(torch.ones(1)) |
| 2149 | self.always = torch.nn.Linear(width, width) |
| 2150 | self.optional = torch.nn.Linear(width, width) |
| 2151 | |
| 2152 | def forward(self, inputs, use_optional): |
| 2153 | result = self.always(inputs) |