4 ms·
For those on NixOS, here's a quick and dirty flake.nix that will let you make a venv in which to "pip install"' Just put it in a flake.nix, and "nix develop" f
by aidenn0 4y ago
For those on NixOS, here's a quick and dirty flake.nix that will let you make a venv in which to "pip install"'
Just put it in a flake.nix, and "nix develop" followed by "virtualenv ./venv; . ./venv/bin/activate; pip install git+https://github.com/openai/whisper.git https://github.com/openai/whisper.git"
{
description = "Python 3.9 development environment";
outputs = { self, nixpkgs }:
let
system = "x86_64-linux";
pkgs = import nixpkgs { inherit system; };
in {
devShells.${system}.default = pkgs.mkShell {
buildInputs = [
pkgs.ffmpeg
pkgs.python39
pkgs.python39Packages.pip
pkgs.python39Packages.numpy
pkgs.python39Packages.pytorch
pkgs.python39Packages.virtualenv
];
};
};
}
- aidenn0 4y agoThis should, in theory, work with CUDA; my GPU doesn't have enough RAM to do it (it runs out at 2.9GiB allocated, I have 4GiB, but am running a compositing desktop, which chews up about 600MiB; not sure where the other ~400MiB went) [edit] I confirmed CUDA worked with the "small" model, which used 3.3GB of GPU ram, and resulted in much poorer recognition than the "medium" model on my CPU (but it ran at least two orders of magnitude faster). { description = "Python 3.9 development environment"; outputs = { self, nixpkgs }: let system = "x86_64-linux"; pkgs = import nixpkgs { inherit system; config.allowUnfree = true; config.cudaSupport = true; }; in { devShells.${system}.default = pkgs.mkShell { buildInputs = with pkgs; [ cudatoolkit linuxPackages.nvidia_x11 cudaPackages.cudnn libGLU libGL xorg.libXi xorg.libXmu freeglut xorg.libXext xorg.libX11 xorg.libXv xorg.libXrandr zlib ncurses5 stdenv.cc binutils ffmpeg python39 python39Packages.pip python39Packages.numpy python39Packages.pytorch-bin python39Packages.virtualenv ]; shellHook = '' export LD_LIBRARY_PATH="${pkgs.linuxPackages.nvidia_x11}/lib" ''; }; }; }
- magicalhippo 4y agoCUDA worked fine with large on my 2080Ti FWIW. The speedup is ridiculous, as expected. My Ryzen 3800X used almost an hour transcribing a minute worth of speech, while the 2080Ti does it in like 10-20 seconds.
- aidenn0 4y agoHow much GPU ram did it use?
- magicalhippo 4y agoI'm on Windows, using Task Manager, the dedicated GPU memory went from 1GB before run to about 9.8GB for the most time during run, peaking at 10.2GB. So pretty close to the 11GB limit of my 2080Ti it seems.