OmPrakashSingh1704 commited on
Commit
cab1be7
·
1 Parent(s): 6e8e48d
options/Video_model/Model.py CHANGED
@@ -67,15 +67,15 @@ def Video(
67
  ).frames[0]
68
  else:
69
  # Use bfloat16 for CPU as it's supported in torch.autocast
70
- with torch.autocast(device_type='cpu', dtype=torch.bfloat16):
71
- frames = pipeline(
72
- image, height=height, width=width,
73
- num_inference_steps=num_inference_steps,
74
- min_guidance_scale=min_guidance_scale,
75
- max_guidance_scale=max_guidance_scale,
76
- num_frames=num_frames, fps=fps, motion_bucket_id=motion_bucket_id,
77
- generator=generator,
78
- ).frames[0]
79
 
80
 
81
  # Save the generated video
 
67
  ).frames[0]
68
  else:
69
  # Use bfloat16 for CPU as it's supported in torch.autocast
70
+ # with torch.autocast(device_type='cpu', dtype=torch.bfloat16):
71
+ frames = pipeline(
72
+ image, height=height, width=width,
73
+ num_inference_steps=num_inference_steps,
74
+ min_guidance_scale=min_guidance_scale,
75
+ max_guidance_scale=max_guidance_scale,
76
+ num_frames=num_frames, fps=fps, motion_bucket_id=motion_bucket_id,
77
+ generator=generator,
78
+ ).frames[0]
79
 
80
 
81
  # Save the generated video
options/Video_model/__pycache__/Model.cpython-310.pyc CHANGED
Binary files a/options/Video_model/__pycache__/Model.cpython-310.pyc and b/options/Video_model/__pycache__/Model.cpython-310.pyc differ