i
This commit is contained in:
parent
6530ddc368
commit
883352cb50
7
entry.py
7
entry.py
@ -70,6 +70,11 @@ def get_batch(keys, value_dict, N, device="cuda"):
|
|||||||
.to(device)
|
.to(device)
|
||||||
.repeat(*N, 1)
|
.repeat(*N, 1)
|
||||||
)
|
)
|
||||||
|
batch_uc["target_size_as_tuple"] = (
|
||||||
|
torch.tensor([value_dict["target_height"], value_dict["target_width"]])
|
||||||
|
.to(device)
|
||||||
|
.repeat(*N, 1) / 2.0
|
||||||
|
)
|
||||||
else:
|
else:
|
||||||
batch[key] = value_dict[key]
|
batch[key] = value_dict[key]
|
||||||
|
|
||||||
@ -95,6 +100,8 @@ sampler = EulerAncestralSampler(
|
|||||||
verbose=True,
|
verbose=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
torch.manual_seed(123)
|
||||||
|
|
||||||
config_path = './sd_xl_base.yaml'
|
config_path = './sd_xl_base.yaml'
|
||||||
config = OmegaConf.load(config_path)
|
config = OmegaConf.load(config_path)
|
||||||
model = instantiate_from_config(config.model).cpu()
|
model = instantiate_from_config(config.model).cpu()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user