- handler.py +2 -2
handler.py
CHANGED
@@ -7,13 +7,13 @@ print(torch.version.cuda)
|
|
7 |
|
8 |
class EndpointHandler():
|
9 |
def __init__(self, path=""):
|
10 |
-
is_production =
|
11 |
|
12 |
os.chdir("/repository" if is_production else "/workspace/eri2")
|
13 |
|
14 |
os.environ['AM_I_DOCKER'] = 'False'
|
15 |
os.environ['BUILD_WITH_CUDA'] = 'True'
|
16 |
-
os.environ['CUDA_HOME'] = '/usr/local/cuda-11.
|
17 |
|
18 |
# Install Segment Anything
|
19 |
subprocess.run(["python", "-m", "pip", "install", "-e", "segment_anything"])
|
|
|
7 |
|
8 |
class EndpointHandler():
|
9 |
def __init__(self, path=""):
|
10 |
+
is_production = True
|
11 |
|
12 |
os.chdir("/repository" if is_production else "/workspace/eri2")
|
13 |
|
14 |
os.environ['AM_I_DOCKER'] = 'False'
|
15 |
os.environ['BUILD_WITH_CUDA'] = 'True'
|
16 |
+
os.environ['CUDA_HOME'] = '/usr/local/cuda-11.7/'
|
17 |
|
18 |
# Install Segment Anything
|
19 |
subprocess.run(["python", "-m", "pip", "install", "-e", "segment_anything"])
|