(
model,
data,
num_input_channels,
num_labels,
label=None,
is_test=False,
no_loss=False,
)
| 174 | |
| 175 | |
| 176 | def create_shufflenet( |
| 177 | model, |
| 178 | data, |
| 179 | num_input_channels, |
| 180 | num_labels, |
| 181 | label=None, |
| 182 | is_test=False, |
| 183 | no_loss=False, |
| 184 | ): |
| 185 | builder = ShuffleNetV2Builder(model, data, num_input_channels, |
| 186 | num_labels, |
| 187 | is_test=is_test) |
| 188 | builder.create() |
| 189 | |
| 190 | if no_loss: |
| 191 | return builder.last_out |
| 192 | |
| 193 | if (label is not None): |
| 194 | (softmax, loss) = model.SoftmaxWithLoss( |
| 195 | [builder.last_out, label], |
| 196 | ["softmax", "loss"], |
| 197 | ) |
| 198 | return (softmax, loss) |
nothing calls this directly
no test coverage detected
searching dependent graphs…