MCPcopy
hub / github.com/dmlc/dgl / validate

Function validate

examples/sparse/sampling/ladies.py:160–164  ·  view source on GitHub ↗
(device, A, ndata, dataset, model, batch_size)

Source from the content-addressed store, hash-verified

158
159
160def validate(device, A, ndata, dataset, model, batch_size):
161 inf_id = dataset.test_idx.to(device)
162 inf_dataloader = torch.utils.data.DataLoader(inf_id, batch_size=batch_size)
163 acc = evaluate(model, A, inf_dataloader, ndata, dataset.num_classes)
164 return acc
165
166
167def train(device, A, ndata, dataset, model):

Callers 1

ladies.pyFile · 0.70

Calls 2

evaluateFunction · 0.70
toMethod · 0.45

Tested by

no test coverage detected