
Recherche avancée
Autres articles (103)
-
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)
Sur d’autres sites (11794)
-
Docker Image for Torchvsion and Torchaudio with FFmpeg with nvidia headers
22 juillet 2024, par Felipe MarraI'm trying to perform GPU video encoding/decoding using PyTorch. This means compiling FFmpeg from source along with Nvidia codec headers.


Currently, my docker image looks like this :


FROM nvcr.io/nvidia/pytorch:24.06-py3

RUN apt-get -yqq update && \
 apt-get install -yq --no-install-recommends ca-certificates expat libgomp1 && \
 apt-get autoremove -y && \
 apt-get clean -y

RUN apt-get install -y bash \
 autoconf \
 automake \
 build-essential \
 cmake \
 git-core \
 libass-dev \
 libfreetype6-dev \
 libgnutls28-dev \
 libmp3lame-dev \
 libnuma1 \
 libnuma-dev \
 libsdl2-dev \
 libtool \
 libva-dev \
 libvdpau-dev \
 libvorbis-dev \
 libxcb1-dev \
 libxcb-shm0-dev \
 libxcb-xfixes0-dev \
 libc6 \
 libc6-dev \
 meson \
 ninja-build \
 pkg-config \
 texinfo \
 unzip \
 wget \
 yasm \
 zlib1g-dev && \
 apt-get -yqq update

# Miniconda
COPY .devcontainer/env.yml .

RUN mkdir -p ~/miniconda3 && \
 wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda3/miniconda.sh && \
 bash ~/miniconda3/miniconda.sh -b -u -p ~/miniconda3 && \
 rm -rf ~/miniconda3/miniconda.sh && \
 ~/miniconda3/bin/conda init bash && \
 ~/miniconda3/bin/conda init zsh && \
 ~/miniconda3/bin/conda env update --file env.yml

# FFMPEG
RUN git clone https://git.videolan.org/git/ffmpeg/nv-codec-headers.git && \
 cd nv-codec-headers && \
 make install

RUN git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg/ && \
 cd ffmpeg && \
 ./configure \
 --prefix="$CONDA_PREFIX"\
 --enable-nonfree \
 --enable-cuda-nvcc \
 --enable-libnpp \
 --extra-cflags=-I/usr/local/cuda/include \
 --extra-ldflags=-L/usr/local/cuda/lib64 \
 --disable-static \
 --enable-shared && \
 make -k -j 8 && \
 make install && \
 ldconfig

ENV LD_LIBRARY_PATH=$CONDA_PREFIX/lib:$LD_LIBRARY_PATH



The env.yml contains the following :


name: base
channels:
 - pytorch
 - nvidia
 - conda-forge
 - defaults
dependencies:
 - pytorch=2.3.1=py3.12_cuda12.1_cudnn8.9.2_0
 - torchvision=0.18.1=py312_cu121
 - torchaudio=2.3.1=py312_cu121
 - pytorch-cuda=12.1=ha16c6d3_5



To test the image, I'm running :


import torchvision
from torchaudio.utils import ffmpeg_utils

print("Library versions:")
print(ffmpeg_utils.get_versions())
print("\nBuild config:")
print(ffmpeg_utils.get_build_config())
print("\nDecoders:")
print([k for k in ffmpeg_utils.get_video_decoders().keys() if "cuvid" in k])
print("\nEncoders:")
print([k for k in ffmpeg_utils.get_video_encoders().keys() if "nvenc" in k])

torchvision.set_video_backend('cuda')



I've also created this repo so that other people will be able to just run this image once its problems get solved.


What is going on is that outside the Conda environment, FFmpeg is configured as expected. But inside it, I'm getting the folowing error :


libopenh264.so.5: cannot open shared object file: No such file or directory



By following this comment on a torchvision issue, I was able to make
ffprobe -hide_banner -decoders | grep h264
andffmpeg -hide_banner -encoders | grep 264
yield the expected outputs, as shown in torchaudio's doc, inside the Conda environment. But then torchaudio wasn't able to find FFmpeg.

I'm new to the whole ecosystem (linux, docker and torch), and would appreciate it if someone could help me build this image, as I think that this should actually be officially provided by torch.


-
Revision 30244 : On mets à jour le script d’encodage pour tester l’encodage multiple (plus ...
26 juillet 2009, par kent1@… — LogOn mets à jour le script d’encodage pour tester l’encodage multiple (plus uniquement en flv)
-
stream_decoder : Two read_metadata() fixes from 1.2.1 maintenance branch.
28 juin 2014, par Erik de Castro Lopostream_decoder : Two read_metadata() fixes from 1.2.1 maintenance branch.
* Fix leaks in read_metadata_() that could occur because of read errors or
malformed streams.
http://flac.cvs.sourceforge.net/viewvc/flac/flac/src/libFLAC/
stream_decoder.c ?
r1=1.147&r2=1.147.2.1&pathrev=FLAC_RELEASE_1_2_1_MAINTENANCE_BRANCH* Fix metadata block initialization bug in read_metadata_().
http://flac.cvs.sourceforge.net/viewvc/flac/flac/src/libFLAC/
stream_decoder.c ?
r1=1.147.2.1&r2=1.147.2.2&pathrev=FLAC_RELEASE_1_2_1_MAINTENANCE_BRANCHPatch-from : lvqcl <lvqcl.mail@gmail.com>