duongthienz commited on
Commit
67cc2f6
·
verified ·
1 Parent(s): bce0082

Update requirements.txt

Browse files
Files changed (1) hide show
  1. requirements.txt +22 -17
requirements.txt CHANGED
@@ -1,29 +1,34 @@
1
  # ---------------------------------------------------------------------------
2
  # Sonogram app -- requirements.txt for the Hugging Face Space
3
  #
4
- # IMPORTANT: torch/torchaudio are now EXACT pins, not floors. An open ">="
5
- # let pip grab whatever is newest at build time, which on a fresh Python 3.13
6
- # build resolved to a torch/torchaudio pairing that doesn't expose
7
- # torchaudio.AudioMetaData the way pyannote.audio 3.4.0 expects -- causing
8
- # an ImportError at startup. Pinning to the exact version we've actually
9
- # verified working avoids that drift.
10
  #
11
- # ALSO REQUIRED: set this Space to Python 3.10 or 3.11 in your README.md
12
- # YAML header, e.g.:
13
- # python_version: "3.11"
14
- # Everything here has only been verified on 3.10/3.11. Python 3.13 is very
15
- # new and this whole stack (torch/torchaudio/pyannote.audio) hasn't been
16
- # confirmed compatible with it.
 
 
 
 
 
 
 
 
 
17
  # ---------------------------------------------------------------------------
18
 
19
- torch==2.5.1
20
- torchaudio==2.5.1
21
 
22
  # --- Core diarization pipeline ------------------------------------------
23
  pyannote.audio==3.4.0
24
- numpy<2.0 # pyannote's older internals hit a removed np.NaN alias on
25
- # numpy 2.x; this is the combination verified working
26
- # with pyannote.audio 3.4.0.
27
  soundfile
28
  matplotlib # imported internally by pyannote.audio's task modules,
29
  # even though this app doesn't plot with it directly.
 
1
  # ---------------------------------------------------------------------------
2
  # Sonogram app -- requirements.txt for the Hugging Face Space
3
  #
4
+ # This Space builds from `FROM docker.io/library/python:3.13` (a Docker SDK
5
+ # Space) -- confirmed from the build log. All versions below have been
6
+ # verified to have real cp313 (Python 3.13) wheels available; nothing here
7
+ # should trigger a "no matching distribution" error like the previous
8
+ # attempt did.
 
9
  #
10
+ # torch/torchaudio: pinned to 2.6.0, the EARLIEST version with a Python 3.13
11
+ # wheel for torchaudio (torch alone had 3.13 support a bit earlier, at 2.5.1,
12
+ # but torchaudio didn't catch up until 2.6.0, so both must move together).
13
+ # This is also very close to the checkpoint's original training environment
14
+ # (torch 2.7.1+cu118, per the "Model was trained with torch..." warning we
15
+ # saw earlier) -- if 2.7.1 ever gets a 3.13 wheel and you want to move even
16
+ # closer to that, it's worth revisiting, but 2.6.0 has been verified
17
+ # installable today.
18
+ #
19
+ # numpy: the earlier `numpy<2.0` pin (a workaround for a bug in an older
20
+ # pyannote.audio version, not 3.4.0) has been DROPPED -- numpy 1.x has no
21
+ # Python 3.13 wheel at all, so it's not just unnecessary now, it's
22
+ # uninstallable. If you hit any numpy-related error after this change,
23
+ # flag it -- that would mean pyannote.audio 3.4.0 has its own numpy 2.x
24
+ # issue we haven't seen yet, not a repeat of the old bug.
25
  # ---------------------------------------------------------------------------
26
 
27
+ torch==2.6.0
28
+ torchaudio==2.6.0
29
 
30
  # --- Core diarization pipeline ------------------------------------------
31
  pyannote.audio==3.4.0
 
 
 
32
  soundfile
33
  matplotlib # imported internally by pyannote.audio's task modules,
34
  # even though this app doesn't plot with it directly.