MCPcopy Create free account
hub / github.com/pytorch/tutorials / create_model

Function create_model

intermediate_source/intermediate_data_loading_tutorial.py:162–164  ·  view source on GitHub ↗

Create a conv+transformer model for benchmarking.

()

Source from the content-addressed store, hash-verified

160
161
162def create_model():
163 """Create a conv+transformer model for benchmarking."""
164 return SmallTransformerModel().to(device)
165
166
167def train_and_benchmark(loader, max_batches=160, epochs=10, prefetch_device=None):

Callers 1

train_and_benchmarkFunction · 0.70

Calls 1

Tested by

no test coverage detected