HumanSignal / HumanSignal/label-studio-ml-backend

401 client error segment_anything_2_image

Open
#749 6 comments 6 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
1.1k
Forks
490
Avg merge
1d 14h
Merged PRs (30d)
3

Description

I got the problem with 401 client error, Authentication credentials were not provided.
I run the `segment_anything_2_image`.
1. try create new token.
2. LABEL_STUDIO_USE_REDIS=true

above of the methods didn't work!
Have anyone have the same situation?Please tell me how to solve it, thx.

![Image](https://github.com/user-attachments/assets/8feffebd-83d3-497b-8bf0-3fbcb9f18775)

![Image](https://github.com/user-attachments/assets/4efd2869-4bb1-419f-9cca-d9b7ef651ad5)
this is my `docker-compose.yml`

```
`version: "3.8"
services:
ml-backend:
container_name: ml-backend
image: humansignal/ml-backend:v0
build:
context: .
args:
TEST_ENV: ${TEST_ENV}
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [ gpu ]
environment:
# specify these parameters if you want to use basic auth for the model server
- BASIC_AUTH_USER=
- BASIC_AUTH_PASS=
# set the log level for the model server
- LOG_LEVEL=DEBUG
# any other parameters that you want to pass to the model server
- ANY=PARAMETER
# specify the number of workers and threads for the model server
- WORKERS=1
- THREADS=8
# specify the model directory (likely you don't need to change this)
- MODEL_DIR=/data/models
# specify device
- DEVICE=cuda # or 'cpu' (coming soon)
# SAM2 model config
- MODEL_CONFIG=configs/sam2.1/sam2.1_hiera_l.yaml
# SAM2 checkpoint
- MODEL_CHECKPOINT=/sam2/checkpoints/sam2.1_hiera_large.pt
# specify port
- PORT=9090

# Specify the Label Studio URL and API key to access
# uploaded, local storage and cloud storage files.
# Do not use 'localhost' as it does not work within Docker containers.
# Use prefix 'http://' or 'https://' for the URL always.
# Determine the actual IP using 'ifconfig' (Linux/Mac) or 'ipconfig' (Windows).
- LABEL_STUDIO_URL=http://192.168.x.xxx:8080
- LABEL_STUDIO_API_KEY=
LABEL_STUDIO_USE_REDIS=true
ports:
- "9090:9090"
volumes:
- "./data/server:/data"
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.