-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #63 from noskill/main
multiple gpu support in worker and loader
- Loading branch information
Showing
34 changed files
with
4,064 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
FROM nvidia/cuda:12.0.0-devel-ubuntu22.04 | ||
RUN apt-get update | ||
RUN apt-get install -y curl libicu70 python3 | ||
# needed by opencv | ||
RUN apt-get -y install ffmpeg libsm6 libxext6 | ||
RUN useradd -ms /bin/bash tester | ||
user tester | ||
workdir /tester | ||
RUN mkdir actions-runner && cd actions-runner | ||
RUN curl -o actions-runner-linux-x64-2.317.0.tar.gz -L https://github.com/actions/runner/releases/download/v2.317.0/actions-runner-linux-x64-2.317.0.tar.gz | ||
RUN echo "9e883d210df8c6028aff475475a457d380353f9d01877d51cc01a17b2a91161d actions-runner-linux-x64-2.317.0.tar.gz" | shasum -a 256 -c | ||
RUN tar xzf ./actions-runner-linux-x64-2.317.0.tar.gz | ||
# GITHUB TOKEN | ||
ARG token=vasya | ||
RUN ./config.sh --url https://github.com/singnet/metafusion --token $token | ||
entrypoint /bin/sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import logging | ||
import threading | ||
|
||
|
||
def thread_id_filter(record): | ||
"""Inject thread_id to log records""" | ||
record.thread_id = threading.get_ident() | ||
return record | ||
|
||
def setup_logger(path='log_file.log'): | ||
logger = logging.getLogger() | ||
logger.setLevel(logging.DEBUG) | ||
fh = logging.FileHandler('log_file.log') | ||
fh.setLevel(logging.DEBUG) | ||
ch = logging.StreamHandler() | ||
ch.setLevel(logging.INFO) | ||
|
||
ch.addFilter(thread_id_filter) | ||
fh.addFilter(thread_id_filter) | ||
formatter = logging.Formatter('%(asctime)s - %(thread)d - %(levelname)s - %(message)s') | ||
fh.setFormatter(formatter) | ||
ch.setFormatter(formatter) | ||
|
||
logger.addHandler(fh) | ||
logger.addHandler(ch) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.