Update app.py
Browse files
app.py
CHANGED
@@ -111,7 +111,7 @@ def process_mask(mask, expand_contract_px, expand, feathering_enabled, feather_s
|
|
111 |
|
112 |
def sam_process(input_image, checkpoint, tracking_points, trackings_input_label, expand_contract_px, expand, feathering_enabled, feather_size):
|
113 |
image = Image.open(input_image)
|
114 |
-
image = np.array
|
115 |
checkpoint_map = {
|
116 |
"tiny": ("./checkpoints/sam2_hiera_tiny.pt", "sam2_hiera_t.yaml"),
|
117 |
"small": ("./checkpoints/sam2_hiera_small.pt", "sam2_hiera_s.yaml"),
|
|
|
111 |
|
112 |
def sam_process(input_image, checkpoint, tracking_points, trackings_input_label, expand_contract_px, expand, feathering_enabled, feather_size):
|
113 |
image = Image.open(input_image)
|
114 |
+
image = np.array(image.convert("RGB"))
|
115 |
checkpoint_map = {
|
116 |
"tiny": ("./checkpoints/sam2_hiera_tiny.pt", "sam2_hiera_t.yaml"),
|
117 |
"small": ("./checkpoints/sam2_hiera_small.pt", "sam2_hiera_s.yaml"),
|