MCPcopy Index your code
hub / github.com/openai/guided-diffusion / load_superres_data

Function load_superres_data

scripts/super_res_train.py:63–72  ·  view source on GitHub ↗
(data_dir, batch_size, large_size, small_size, class_cond=False)

Source from the content-addressed store, hash-verified

61
62
63def load_superres_data(data_dir, batch_size, large_size, small_size, class_cond=False):
64 data = load_data(
65 data_dir=data_dir,
66 batch_size=batch_size,
67 image_size=large_size,
68 class_cond=class_cond,
69 )
70 for large_batch, model_kwargs in data:
71 model_kwargs["low_res"] = F.interpolate(large_batch, small_size, mode="area")
72 yield large_batch, model_kwargs
73
74
75def create_argparser():

Callers 1

mainFunction · 0.85

Calls 1

load_dataFunction · 0.90

Tested by

no test coverage detected