Skip to content
This repository has been archived by the owner on Oct 11, 2024. It is now read-only.

Fix nightly benchmark scripts #229

Merged
merged 1 commit into from
May 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions neuralmagic/benchmarks/common.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import itertools
import json
import os
from argparse import Namespace
from pathlib import Path
from typing import Iterable, NamedTuple
Expand All @@ -14,9 +15,13 @@

def download_model(model: str) -> None:
"""
Downloads a hugging face model to cache
"""
download_weights_from_hf(model)
Downloads a hugging face model to cache
"""
cache_dir = os.getenv("HF_HOME")
allow_patterns = ["*.safetensors", "*.bin"]
download_weights_from_hf(model,
cache_dir=cache_dir,
allow_patterns=allow_patterns)
get_tokenizer(model)


Expand Down
Loading