Skip to content

Commit

Permalink
tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
mthrok committed Jul 12, 2023
1 parent 66f6827 commit 63d4eb3
Showing 1 changed file with 17 additions and 23 deletions.
40 changes: 17 additions & 23 deletions .github/workflows/build_docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ jobs:
export CU_VERSION="${{ matrix.cuda_arch_version }}"
export CUDATOOLKIT="pytorch-cuda=${CU_VERSION}"
export FFMPEG_VERSION=6.0
export CODEC_HEADER_VERSION=n12.0.16.0
export CODEC_HEADER_VERSION=n12.0.16.0
export COMPUTE_CAPABILITY=86
export BUILD_VERSION="$( cut -f 1 -d a version.txt )".dev"$(date "+%Y%m%d")"
# Set CHANNEL
if [[(${GITHUB_EVENT_NAME} = 'pull_request' && (${GITHUB_BASE_REF} = 'release'*)) || (${GITHUB_REF} = 'refs/heads/release'*) ]]; then
Expand All @@ -53,8 +53,22 @@ jobs:
conda create --quiet -y --prefix ci_env python="${PYTHON_VERSION}"
conda activate ./ci_env
# Install PyTorch / TorchAudio first
set -ex
set +u # don't know why
conda install \
--yes \
--quiet \
-c "pytorch-${CHANNEL}" \
-c nvidia "pytorch-${CHANNEL}"::pytorch[build="*${CU_VERSION}*"] \
"${CUDATOOLKIT}"
# Install torchaudio
conda install --quiet --yes pkg-config cmake>=3.18.0 ninja
pip install --progress-bar off -v -e . --no-use-pep517
# Install FFmpeg-dependencies
conda install --quiet -y -c conda-forge yasm x264 gnutls pkg-config lame libopus libvpx openh264 openssl x264
conda install --quiet --yes -c conda-forge yasm x264 gnutls pkg-config lame libopus libvpx openh264 openssl x264
# Build FFmpeg with NVIDIA Video Codec SDK
# TODO cache this
Expand Down Expand Up @@ -97,26 +111,6 @@ jobs:
# ffmpeg -y -vsync 0 -hwaccel cuvid -hwaccel_output_format cuda -c:v h264_cuvid -resize 360x240 -i "${src}" -c:a copy -c:v h264_nvenc -b:v 5M test.mp4
)
# Install PyTorch
set -ex
set +u # don't know why
conda install \
--yes \
--quiet \
-c "pytorch-${CHANNEL}" \
-c nvidia "pytorch-${CHANNEL}"::pytorch[build="*${CU_VERSION}*"] \
"${CUDATOOLKIT}"
# Install torchaudio
# TODO: Enable NVDec/NVEnc
conda install --quiet -y pkg-config
pip --quiet install cmake>=3.18.0 ninja
BUILD_VERSION=$( cut -f 1 -d a version.txt )
BUILD_VERSION=$BUILD_VERSION.dev$(date "+%Y%m%d")
export BUILD_VERSION
FFMPEG_ROOT=${CONDA_PREFIX} USE_CUDA=1 pip install --progress-bar off -v -e . --no-use-pep517
# Install runtime dependencies
pip --quiet install git+https://github.com/kpu/kenlm/ flashlight-text
Expand Down

0 comments on commit 63d4eb3

Please sign in to comment.