[bugfix][Cli Inference] Resolve runtime errors when running fastvideo generate (#495)

This commit is contained in:
Wei Zhou
2025-06-10 02:50:21 -04:00
committed by GitHub
parent 6519b57aab
commit a6aa21bd07
+2 -3
View File
@@ -387,9 +387,8 @@ class FastVideoArgs:
# Use getattr with default value from the dataclass for potentially missing attributes
else:
default_value = getattr(cls, attr, None)
attr = getattr(args, attr, default_value) # type: ignore
if attr is not None:
kwargs[attr] = attr
if getattr(args, attr, default_value) is not None:
kwargs[attr] = getattr(args, attr, default_value)
return cls(**kwargs)