← back to Exo
move model fix
ce9231ad3d5d600ac9d74af02a6f6c3c9d62b14c · 2024-11-19 07:56:20 -0800 · josh
Files touched
M exo/download/hf/hf_helpers.pyM scripts/build_exo.pyM setup.py
Diff
commit ce9231ad3d5d600ac9d74af02a6f6c3c9d62b14c
Author: josh <eyasufikru567@gmail.com>
Date: Tue Nov 19 07:56:20 2024 -0800
move model fix
---
exo/download/hf/hf_helpers.py | 15 ++++++++-------
scripts/build_exo.py | 6 +++---
setup.py | 2 +-
3 files changed, 12 insertions(+), 11 deletions(-)
diff --git a/exo/download/hf/hf_helpers.py b/exo/download/hf/hf_helpers.py
index 7a56ae27..97288bd7 100644
--- a/exo/download/hf/hf_helpers.py
+++ b/exo/download/hf/hf_helpers.py
@@ -110,13 +110,14 @@ async def move_models_to_hf(seed_dir: Union[str, Path]):
source_dir = Path(seed_dir)
dest_dir = get_hf_home()/"hub"
await aios.makedirs(dest_dir, exist_ok=True)
- async for path in source_dir.iterdir():
- if path.is_dir() and path.startswith("models--"):
- dest_path = dest_dir / path.name
- if dest_path.exists():
- if DEBUG>=1: print(f"skipping moving {dest_path}. File already exists")
- else:
- await aios.rename(str(path), str(dest_path))
+ for path in source_dir.iterdir():
+ if path.is_dir() and path.name.startswith("models--"):
+ dest_path = dest_dir / path.name
+ if dest_path.exists():
+ if DEBUG >= 1:
+ print(f"skipping moving {dest_path}. File already exists")
+ else:
+ await aios.rename(str(path), str(dest_path))
async def fetch_file_list(session, repo_id, revision, path=""):
diff --git a/scripts/build_exo.py b/scripts/build_exo.py
index 556ad3cc..cee0ef72 100644
--- a/scripts/build_exo.py
+++ b/scripts/build_exo.py
@@ -2,8 +2,6 @@ import site
import subprocess
import sys
import os
-import pkgutil
-
def run():
site_packages = site.getsitepackages()[0]
command = [
@@ -24,6 +22,7 @@ def run():
"--macos-app-mode=gui",
"--macos-app-version=0.0.1",
"--macos-signed-app-name=com.exolabs.exo",
+ "--macos-sign-notarization",
"--include-distribution-meta=mlx",
"--include-module=mlx._reprlib_fix",
"--include-module=mlx._os_warning",
@@ -33,7 +32,7 @@ def run():
"--nofollow-import-to=tinygrad"
])
inference_modules = [
- name for _, name, _ in pkgutil.iter_modules(['exo/inference/mlx/models'])
+ name for _, name, _ in pkgutil.iter_modules(['exo/inference/models'])
]
for module in inference_modules:
command.append(f"--include-module=exo.inference.mlx.models.{module}")
@@ -48,6 +47,7 @@ def run():
"--include-distribution-metadata=pygments",
"--linux-icon=docs/exo-rounded.png"
])
+
try:
subprocess.run(command, check=True)
print("Build completed!")
diff --git a/setup.py b/setup.py
index c337fd9e..4f2769d5 100644
--- a/setup.py
+++ b/setup.py
@@ -24,7 +24,7 @@ install_requires = [
"rich==13.7.1",
"tenacity==9.0.0",
"tqdm==4.66.4",
- "transformers==4.46.3",
+ "transformers==4.43.3",
"uuid==1.30",
"tinygrad @ git+https://github.com/tinygrad/tinygrad.git@232edcfd4f8b388807c64fb1817a7668ce27cbad",
]
← 8f78c781 Refactors to simplify messaging and properly batch inputs
·
back to Exo
·
missing lib 8bc82322 →