aradootle commited on
Commit
73cb701
1 Parent(s): 1810c2f
Files changed (2) hide show
  1. handler.py +1 -0
  2. requirements.txt +3 -3
handler.py CHANGED
@@ -9,6 +9,7 @@ class EndpointHandler():
9
  # Preload all the elements you are going to need at inference.
10
  model_type = "vit_b"
11
  # prefix = "/opt/ml/model"
 
12
  model_path = "models/tf_model.h5"
13
  # model_checkpoint_path = os.path.join(prefix, "sam_vit_h_4b8939.pth")
14
  sam = sam_model_registry[model_type](checkpoint=model_path)
 
9
  # Preload all the elements you are going to need at inference.
10
  model_type = "vit_b"
11
  # prefix = "/opt/ml/model"
12
+ print('current working directory', os.getcwd())
13
  model_path = "models/tf_model.h5"
14
  # model_checkpoint_path = os.path.join(prefix, "sam_vit_h_4b8939.pth")
15
  sam = sam_model_registry[model_type](checkpoint=model_path)
requirements.txt CHANGED
@@ -1,6 +1,6 @@
1
- # -f https://download.pytorch.org/whl/cu117/torch_stable.html
2
- # torch
3
- # torchvision
4
  git+https://github.com/ara-vardanyan/segment-anything.git
5
  flask
6
  requests
 
1
+ -f https://download.pytorch.org/whl/cu117/torch_stable.html
2
+ torch
3
+ torchvision
4
  git+https://github.com/ara-vardanyan/segment-anything.git
5
  flask
6
  requests