Skip to content

Commit 5541c42

Browse files
Merge branch 'master' into sam2_docker
2 parents 7796205 + 67d606f commit 5541c42

File tree

7 files changed

+51
-4
lines changed

7 files changed

+51
-4
lines changed

.github/workflows/build.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ env:
1313
DOCKER_BUILD_CONFIG_BRANCH: "master"
1414
DOCKER_BUILD_CONFIG_PATH: ".github/docker-build-config.yml"
1515
DOCKER_EXAMPLES_DIRECTORY: "label_studio_ml/examples"
16+
SLACK_NOTIFICATION_CHANNEL_ID: "CKL2D6D2P"
1617

1718
jobs:
1819
build-image:
@@ -81,7 +82,7 @@ jobs:
8182
echo "image_branch_version=$image_branch_version" >> $GITHUB_OUTPUT
8283
8384
- name: Set up Docker Buildx
84-
uses: docker/setup-buildx-action@v3.8.0
85+
uses: docker/setup-buildx-action@v3.9.0
8586

8687
- name: Login to DockerHub
8788
if: ${{ !github.event.pull_request.head.repo.fork }}
@@ -151,3 +152,24 @@ jobs:
151152
const docker_build_config = yaml.load(docker_build_config_content);
152153
153154
core.setOutput("matrix-include", docker_build_config);
155+
156+
notification:
157+
name: "Send Slack Notification"
158+
if: failure()
159+
runs-on: ubuntu-latest
160+
needs:
161+
- build-image
162+
steps:
163+
- name: Send Slack Notification
164+
if: always()
165+
uses: slackapi/[email protected]
166+
env:
167+
WORKFLOW: "<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}|workflow>"
168+
with:
169+
method: chat.postMessage
170+
token: ${{ secrets.SLACK_LSE_BOT_TOKEN }}
171+
payload: |
172+
channel: "${{ env.SLACK_NOTIFICATION_CHANNEL_ID }}"
173+
text: >+
174+
:x: Build workflow failed
175+
[ ${{ env.WORKFLOW }} ]

.github/workflows/tests.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ env:
2727
DOCKER_BUILD_CONFIG_BRANCH: "master"
2828
DOCKER_BUILD_CONFIG_PATH: ".github/docker-build-config.yml"
2929
DOCKER_EXAMPLES_DIRECTORY: "label_studio_ml/examples"
30+
SLACK_NOTIFICATION_CHANNEL_ID: "CKL2D6D2P"
3031

3132
jobs:
3233
run_pytest:
@@ -241,3 +242,24 @@ jobs:
241242
env:
242243
PR_URL: ${{ github.event.pull_request.html_url }}
243244
GITHUB_TOKEN: ${{ secrets.GIT_PAT }}
245+
246+
notification:
247+
name: "Send Slack Notification"
248+
if: failure() && github.event_name == 'schedule'
249+
runs-on: ubuntu-latest
250+
needs:
251+
- run_pytest
252+
steps:
253+
- name: Send Slack Notification
254+
if: always()
255+
uses: slackapi/[email protected]
256+
env:
257+
WORKFLOW: "<https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}|workflow>"
258+
with:
259+
method: chat.postMessage
260+
token: ${{ secrets.SLACK_LSE_BOT_TOKEN }}
261+
payload: |
262+
channel: "${{ env.SLACK_NOTIFICATION_CHANNEL_ID }}"
263+
text: >+
264+
:x: Scheduled test workflow failed
265+
[ ${{ env.WORKFLOW }} ]

label_studio_ml/examples/flair/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ services:
1414
- WORKERS=1
1515
- THREADS=8
1616
- LOG_LEVEL=DEBUG
17-
- FLAIR_MODEL_NAME=ner
17+
- FLAIR_MODEL_NAME=ner-multi
1818
ports:
1919
- "9090:9090"

label_studio_ml/examples/flair/model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
logger = logging.getLogger(__name__)
1111

12-
FLAIR_MODEL_NAME = os.getenv("FLAIR_MODEL_NAME", "ner")
12+
FLAIR_MODEL_NAME = os.getenv("FLAIR_MODEL_NAME", "ner-multi")
1313
logger.info(f"Loading Flair model {FLAIR_MODEL_NAME}")
1414
_model = Classifier.load(FLAIR_MODEL_NAME)
1515

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
scipy==1.10.1
2-
flair==0.13.1
2+
torch==2.5.1
3+
flair==0.15

label_studio_ml/examples/segment_anything_2_image/docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ services:
1616
count: 1
1717
capabilities: [ gpu ]
1818

19+
1920
environment:
2021
# specify these parameters if you want to use basic auth for the model server
2122
- BASIC_AUTH_USER=

label_studio_ml/examples/yolo/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ RUN --mount=type=cache,target="/var/cache/apt",sharing=locked \
1111
apt-get -y update \
1212
&& apt-get install -y git \
1313
&& apt-get install -y wget \
14+
&& apt-get install -y curl \
1415
&& apt-get install -y g++ freeglut3-dev build-essential libx11-dev \
1516
libxmu-dev libxi-dev libglu1-mesa libglu1-mesa-dev libfreeimage-dev \
1617
&& apt-get -y install ffmpeg libsm6 libxext6 libffi-dev python3-dev python3-pip gcc

0 commit comments

Comments
 (0)