Compare commits

..

No commits in common. "e79bd5f9a7bbe6e200dcda8f7feb6ab0f8133f21" and "c0d9e168b3cd27f071d9434846851ce05765688d" have entirely different histories.

4 changed files with 3 additions and 48 deletions

View File

@ -59,12 +59,6 @@ jobs:
mkdir -p /tmp/llama-cpp-python/
docker cp prebuilt-container:/tmp/llama-cpp-python/dist/ /tmp/llama-cpp-python/
# Step 6: Copy xformers wheel artifact to host
- name: Copy xformers wheel to host
run: |
mkdir -p /tmp/xformers/
docker cp prebuilt-container:/tmp/xformers/dist/ /tmp/xformers/
# Step 7: Upload bitsandbytes wheel artifact
- name: Upload bitsandbytes wheel
uses: actions/upload-artifact@v4
@ -79,14 +73,7 @@ jobs:
name: llama-cpp-python-wheels
path: /tmp/llama-cpp-python/dist/*.whl
# Step 9: Upload xformers wheel artifact
- name: Upload xformers wheel
uses: actions/upload-artifact@v4
with:
name: xformers-wheels
path: /tmp/xformers/dist/*.whl
# Step 10: Cleanup Docker container
# Step 9: Cleanup Docker container
- name: Cleanup
run: |
docker rm prebuilt-container

View File

@ -39,6 +39,7 @@ class Stack:
self.pid = config.get(f"{self.name}-pid")
def install(self):
if self.is_installed():
self.update()
@ -73,10 +74,8 @@ class Stack:
self.stop()
logger.info(f"Updating {self.name}")
symlinks = utils.find_symlink_in_folder(self.path)
self.git_pull(folder)
self._update()
utils.create_symlinks(symlinks)
if status:
self.start()

View File

@ -1,9 +1,7 @@
import importlib
import json
import os
import shutil
import subprocess
from pathlib import Path
from urllib import request, error
from core.stack import Stack
@ -81,24 +79,3 @@ def load_service_from_string(service: str) -> Stack:
met = getattr(module, service_name)
return met()
def find_symlink_in_folder(folder: str):
symlinks = {}
for file in Path(folder).rglob("webui/**"):
if file.is_symlink():
symlinks[file] = file.resolve()
return symlinks
def create_symlinks(symlinks: dict[Path, Path]):
for target, link in symlinks.items():
logger.debug(f"(re)Creating symlink: {link} -> {target}")
if target.is_symlink():
target.unlink()
if target.exists() and target.is_dir():
shutil.rmtree(target)
os.symlink(link, target)

View File

@ -15,12 +15,4 @@ python3.10 setup.py bdist_wheel --universal
## Clone repo and install python requirements
git clone --recurse-submodules https://github.com/abetlen/llama-cpp-python.git /tmp/llama-cpp-python
cd /tmp/llama-cpp-python
CMAKE_ARGS="-D GGML_HIPBLAS=on -D AMDGPU_TARGETS=${GPU_TARGETS}" FORCE_CMAKE=1 python3.10 -m build --wheel
# ROCM xformers
## Clone repo and install python requirements
pip3 install ninja
git clone --depth 1 https://github.com/facebookresearch/xformers.git /tmp/xformers
cd /tmp/xformers
python3.10 setup.py bdist_wheel --universal
CMAKE_ARGS="-D GGML_HIPBLAS=on -D AMDGPU_TARGETS=${GPU_TARGETS}" FORCE_CMAKE=1 python3.10 -m build --wheel