Spaces:
Paused
Paused
wdt commited on
Commit ·
0fd9834
1
Parent(s): b0ccaf8
fixing cache issue
Browse files25 unmodified lines2627282930313225 unmodified linescache_dir = "/tmp/huggingface_cache"os.makedirs(cache_dir, exist_ok=True)logger.info(f"Using cache directory: {cache_dir}")# Try loading with pipeline first (simpler approach)generator = pipeline(25 unmodified lines2627282930313233343536373825 unmodified linescache_dir = "/tmp/huggingface_cache"os.makedirs(cache_dir, exist_ok=True)# Set environment variable to force use of our cache directoryos.environ["HF_HOME"] = cache_diros.environ["TRANSFORMERS_CACHE"] = cache_dirlogger.info(f"Using cache directory: {cache_dir}")logger.info(f"HF_HOME set to: {os.environ.get('HF_HOME')}")logger.info(f"TRANSFORMERS_CACHE set to: {os.environ.get('TRANSFORMERS_CACHE')}")# Try loading with pipeline first (simpler approach)generator = pipeline(
app/main.py+6