diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml new file mode 100644 index 0000000..0eff66e --- /dev/null +++ b/.github/workflows/main.yaml @@ -0,0 +1,38 @@ + +name: Publish + +on: + push: + branches: + - main + +jobs: + publish: + name: Publish Image + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Free Disk space + shell: bash + run: | + df -h + sudo rm -rf /usr/local/lib/android # will release about 10 GB if you don't need Android + sudo rm -rf /usr/share/dotnet # will release about 20GB if you don't need .NET + sudo rm -rf /opt/ghc + sudo rm -rf "/usr/local/share/boost" + sudo rm -rf "$AGENT_TOOLSDIRECTORY" + df -h + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: Login to DockerHub + uses: docker/login-action@v1 + with: + username: hal9ai + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + push: true + tags: hal9ai/hal9-runtime:latest,hal9ai/hal9-runtime:0.0.1 diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..89c4e13 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM pytorch/pytorch:2.1.2-cuda11.8-cudnn8-devel +WORKDIR /app/ + +RUN apt-get update +RUN apt-get -y install curl gnupg +RUN curl -fsSL https://deb.nodesource.com/setup_19.x | bash - +RUN apt-get -y install nodejs +RUN apt-get -y install wget + +RUN apt-get -y install cpanminus +RUN cpanm Image::ExifTool + +RUN npm -v +RUN npm install --save exiftool-vendored + +COPY ./requirements.txt /app/requirements.txt +RUN pip install --no-cache-dir --upgrade -r /app/requirements.txt \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..447fc08 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 hal9.ai + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..32ec3c5 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# hal9-runtime + +Provides a Docker project for Hal9 custom runtime. diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..70c8379 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,19 @@ +aiofiles==23.1.0 +fastapi +pydantic +uvicorn[standard] +pandas==1.5.3 +pyexiftool==0.5.5 +python-multipart==0.0.5 +numpy==1.24.2 +# torch +torchvision +scikit-learn==1.2.2 +scikit-image==0.19.3 +requests==2.28.2 +redis +transformers +httpx +imageio[opencv] +imageio[pyav] +Pillow