ruff linter

This commit is contained in:
lodestone-rock 2025-12-09 11:22:34 +07:00
parent a22b6cfbe6
commit 34ecc0e0fc
2 changed files with 2 additions and 2 deletions

View File

@ -284,7 +284,7 @@ class ChromaRadiance(Chroma):
# non zero during training to prevent 0 div
eps = 0.0
return (noisy - predicted) / (timesteps.view(-1,1,1,1) + eps)
def _forward(
self,
x: Tensor,

View File

@ -257,7 +257,7 @@ def detect_unet_config(state_dict, key_prefix, metadata=None):
dit_config["nerf_tile_size"] = 512
dit_config["nerf_final_head_type"] = "conv" if f"{key_prefix}nerf_final_layer_conv.norm.scale" in state_dict_keys else "linear"
dit_config["nerf_embedder_dtype"] = torch.float32
if f"__x0__" in state_dict_keys: # x0 pred
if "__x0__" in state_dict_keys: # x0 pred
dit_config["use_x0"] = True
else:
dit_config["guidance_embed"] = "{}guidance_in.in_layer.weight".format(key_prefix) in state_dict_keys