Spaces:
Running on Zero
Running on Zero
Commit History
-
Add missing spaces import for @spaces.GPU decorators Running
_sequence_log_probs and _mutation_llrs were decorated with @spaces.GPU (correct - these are the functions that actually run the model on ZeroGPU) but the module never imported spaces, which would NameError on load. Imported it ahead of torch, matching app_gradio.py's ordering. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>b6c6e48 -
Remove dangling streamlit imports, add precomputed matrix data
src/structure.py and src/uniprot.py still had "import streamlit as st" left over from the Gradio migration (unused even then - only the @st.cache_data decorators were stripped, not the import). Since streamlit was dropped from requirements.txt, this crashed the deployed Space with ModuleNotFoundError as soon as either module loaded. Also adds data/matrices/*.npz (precomputed LLR matrices) and data/raw/*.fasta from ../kcng, so "Load precomputed matrix" has accessions to show instead of an empty list. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>9775cc8 -
Restore missing src modules, fix esm/gradio dependency conflict
app.py and app_gradio.py imported src.config, src.matrices, src.model, src.sequences, and src.viz, but only their .pyc caches had ever been committed (no .gitignore) — the app couldn't actually start. Ported the real sources from ../kcng, swapping model.py's st.cache_resource for functools.lru_cache since there's no Streamlit here. model.py needs esm>=3.4.0 for the EsmcForMaskedLM/EsmcTokenizer API, but every transformers 4.x release (which is all esm currently supports) caps huggingface-hub<1.0, while gradio>=6.18.0 requires huggingface-hub>=1.2.0 — an unsatisfiable conflict, not just a slow resolve. Pinned the Space's sdk_version to 6.17.3 (last compatible release) and added esm/altair to requirements.txt. Also stopped tracking __pycache__/ (added .gitignore) and corrected README's stale Streamlit-era instructions. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>fe8c5d0 -
complete the migration to gradio
b1e751b