Spaces:
Running
on
Zero
Running
on
Zero
drscotthawley
commited on
Commit
•
8b092f7
1
Parent(s):
00f0740
fixed zero def
Browse files
app.py
CHANGED
@@ -35,6 +35,8 @@ from sample import zero_wrapper
|
|
35 |
from pom.pianoroll import regroup_lines, img_file_2_midi_file, square_to_rect, rect_to_square
|
36 |
from pom.square_to_rect import square_to_rect
|
37 |
|
|
|
|
|
38 |
CT_HOME = '.'
|
39 |
|
40 |
@spaces.GPU
|
@@ -112,7 +114,6 @@ class Args:
|
|
112 |
def process_image(image, repaint, busyness):
|
113 |
|
114 |
print("CUDA check:")
|
115 |
-
zero = torch.Tensor([0]).cuda()
|
116 |
print(" zero.device = ",zero.device)
|
117 |
accelerator = accelerate.Accelerator()
|
118 |
device = accelerator.device
|
|
|
35 |
from pom.pianoroll import regroup_lines, img_file_2_midi_file, square_to_rect, rect_to_square
|
36 |
from pom.square_to_rect import square_to_rect
|
37 |
|
38 |
+
zero = torch.Tensor([0]).cuda() # used for gpu checking later
|
39 |
+
|
40 |
CT_HOME = '.'
|
41 |
|
42 |
@spaces.GPU
|
|
|
114 |
def process_image(image, repaint, busyness):
|
115 |
|
116 |
print("CUDA check:")
|
|
|
117 |
print(" zero.device = ",zero.device)
|
118 |
accelerator = accelerate.Accelerator()
|
119 |
device = accelerator.device
|