Changeset 37658 for gs3-extensions
- Timestamp:
- 2023-04-13T13:45:45+12:00 (13 months ago)
- Location:
- gs3-extensions/structured-audio/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
gs3-extensions/structured-audio/trunk/TEST-DIARIZATION.sh
r37657 r37658 3 3 source ./_config.bash 4 4 5 test_audio_filename=${1:-test-audio/tst00.wav} 5 test_audio_ifilename=${1:-test-audio/tst00.wav} 6 test_csv_ofilename=${test_audio_ifilename%.*}.csv 6 7 7 test_dir=${test_audio_filename%/*} 8 test_file=${test_audio_filename##*/} 8 ./bin/script/diarization.py $test_audio_ifilename $test_csv_ofilename 9 9 10 ./bin/script/diarization.py $test_audio_filename test-audio/tst00.csv11 10 11 echo "" 12 echo "Diarization output file:" 13 echo " $test_csv_ofilename" 14 echo "" -
gs3-extensions/structured-audio/trunk/_config.bash
r37656 r37658 16 16 echo "" 17 17 echo "Warning: Environment variable PYTHON3_HOME not set" 18 elif [ "$PYTHON3_HOME" != "$GSDL3_EXTCLI_HOME/selfcontained-python3" ] ; then 19 echo "" 20 echo "Warning: Environment variable PYTHON3_HOME is set, but is not the " 21 echo " directory \$GSDL3_EXTCLI_HOME/selfcontained-python3:" 22 echo " $GSDL3_EXTCLI_HOME/selfcontained-python3" 18 else 19 PYTHON3_PARENT_HOME=${PYTHON3_HOME%/*} 20 if [ "$PYTHON3_PARENT_HOME" != "$GSDL3_EXTCLI_HOME/selfcontained-python3" ] ; then 21 echo "" 22 echo "Warning: Environment variable PYTHON3_HOME is set, but its immediate parent directory " 23 echo " is not the directory \$GSDL3_EXTCLI_HOME/selfcontained-python3:" 24 echo " $GSDL3_EXTCLI_HOME/selfcontained-python3" 25 fi 23 26 fi 24 27 … … 32 35 fi 33 36 37 echo "" 34 38 echo "Changing the value of \$HOME to:" 35 39 echo " $HOME" 36 echo "So pip installed packages (which can consume significant disk space)" 40 echo "" 41 echo "This is so pip installed packages (which can consume significant disk space)" 37 42 echo "are stored in the same area as the Greenstone installation, rather" 38 43 echo "than the user's home" -
gs3-extensions/structured-audio/trunk/bin/script/diarization.py.in
r37656 r37658 1 1 #!/usr/bin/env python3 2 2 3 from pyannote.audio import Pipeline 3 4 from pathlib import Path … … 6 7 # remove available graphic cards to trigger cpu default 7 8 os.environ["CUDA_VISIBLE_DEVICES"] = "" 9 10 if os.environ["GSDL3_EXTCLI_HOME"] is not None and os.environ["GSDL3_EXTCLI_HOME"] != "": 11 os.environ["HOME"]=os.path.join(os.environ["GSDL3_EXTCLI_HOME"],"python3-user-home") 12 print("Setting HOME=%s for pyannote models" % os.environ["HOME"]) 13 8 14 9 15 from huggingface_hub import HfApi
Note:
See TracChangeset
for help on using the changeset viewer.